C++ coding

Translate the program below into PEP/8 assembly language

• Use a jump table to implement the switch statement.

• Use trace tags on all variables.

• For invalid scores, output should be the same as the C++ program.

• Add something to the output that makes this program uniquely yours.

• The variable finish needs to be local.

a) Comment lines of the source code to trace the C++ code. Cut & paste the Source Code Listing into your assignment document.

b) Run for each score and paste a screen shot of each of the PEP/8 Output area.

c) Step thru & Cut and paste the memory trace at any point.

#include <iostream>

using namespace std;

int main () { int finish;

cout << “Enter your score: 1, 2, 3, 4, or 5” << endl; cin >> finish;

switch (finish) { case 1:

cout << “you’re first!” << endl;

break; case 2:

cout << “you’re second!” << endl;

break; case 3: case 4:

cout << “you’re not first or second” << endl;



cout << “you weren’t even competing” << endl;


cout << endl; return 0;



Looking for help with your homework?
Grab a 30% Discount and Get your paper done!

30% OFF
Turnitin Report
Title Page
Place an Order

Grab A 14% Discount on This Paper
Pages (550 words)
Approximate price: -