Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Problem 6 6a (4 points) Write an assembly language program that corresponds to the C++ program: Comment each line except STOP and .END. Add something

Problem 6

  • 6a (4 points) Write an assembly language program that corresponds to the C++ program:
    • Comment each line except STOP and .END.
    • Add something to the output that makes this program uniquely yours.
    • Cut and paste Source Code into your document.
  • 6b (4 points) Run it twice once with values that yield an output that is within the range of the Pep8 and once with values that yield an output that is outside the range of the Pep8. Explain the limits. Paste screen shots of the Output area of the Pep8 for both runs
  • 6c (2 points) Explain the status bits NZVC at the point that STOP is loaded for the invalid run.

/******************

HW3P6

******************/

#include

using namespace std;

int a;

int b;

int c;

int d;

int sum;

int ave;

int main(){

cin>>a>>b>>c>>d;

sum = a+b+c+d;

ave = sum/2/2;

cout<<"input a = "<

cout<<"input b = "<

cout<<"input c = "<

cout<<"input d = "<

cout<

cout<<"sum = "<

cout<<"average = "<

return 0;

}

6a Source Code

6b Output for both runs

6c Explain the status bits NZVC for the invalid runs

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Beginning Apache Cassandra Development

Authors: Vivek Mishra

1st Edition

1484201426, 9781484201428

More Books

Students also viewed these Databases questions

Question

Write Hund's rule?

Answered: 1 week ago