logo Hurry, Grab up to 30% discount on the entire course
Order Now logo

Ask This Question To Be Solved By Our ExpertsGet A+ Grade Solution Guaranteed

expert
Bhargav AppasaniEngineering
(/5)

569 Answers

Hire Me
expert
Rishi AggarwalGeneral article writing
(5/5)

589 Answers

Hire Me
expert
Sabir AhmadFinance
(5/5)

749 Answers

Hire Me
expert
Charu SinghalStatistics
(/5)

903 Answers

Hire Me
Assembly Programming

Develop a program that uses four signed, global, short variables A, B, C, D Initialize each variable A, B, C, D to a different positive one-digit value Somehow print the four values in order A B C D, space separated Print a newline character

INSTRUCTIONS TO CANDIDATES
ANSWER ALL QUESTIONS

Question 1

  1. Develop a program that uses four signed, global, short variables A, B, C, D

Initialize each variable A, B, C, D to a different positive one-digit value

Somehow print the four values in order A B C D, space separated

Print a newline character

Reorder the values in the variables from the order A, B, C, D to B, C, D, A

  • A -> B
  • B -> C
  • C -> D
  • D -> A

Somehow print the four values in order A B C D, space separated

 

Question 2

  1. Convert this C++ program exactly as you see it into x86 assembly language:

    #include <iostream>

    unsigned int x;
    unsigned int c;
    unsigned int result;

    // f(x) = 8x + c
    // Make sure to push and pop all necessary registers to the stack to
    // ensure only the EAX register is modified upon return from the function
    unsigned int Equation(unsigned int x, unsigned int c)
    {
      // You CANNOT use the mul or imul operations to perform the multiplication
        return (8 * x) + c;
    }

    void main()
    {
        std::cout << "Enter a value for x: ";
        std::cin >> x;
        std::cout << "Enter a value for c: ";
        std::cin >> c;
        result = Equation(x, c);
        std::cout << "f(x) = " << result << std::endl;
        system("PAUSE");
    }

 

Related Questions

. The fundamental operations of create, read, update, and delete (CRUD) in either Python or Java

CS 340 Milestone One Guidelines and Rubric  Overview: For this assignment, you will implement the fundamental operations of create, read, update,

. Develop a program to emulate a purchase transaction at a retail store. This  program will have two classes, a LineItem class and a Transaction class

Retail Transaction Programming Project  Project Requirements:  Develop a program to emulate a purchase transaction at a retail store. This

. The following program contains five errors. Identify the errors and fix them

7COM1028   Secure Systems Programming   Referral Coursework: Secure

. Accepts the following from a user: Item Name Item Quantity Item Price Allows the user to create a file to store the sales receipt contents

Create a GUI program that:Accepts the following from a user:Item NameItem QuantityItem PriceAllows the user to create a file to store the sales receip

. The final project will encompass developing a web service using a software stack and implementing an industry-standard interface. Regardless of whether you choose to pursue application development goals as a pure developer or as a software engineer

CS 340 Final Project Guidelines and Rubric  Overview The final project will encompass developing a web service using a software stack and impleme