answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
CaHeK987 [17]
2 years ago
12

In the description of the Hack machine language in chapter 4, it is stated that in well-written programs a C-instruction that ma

y cause a jump should not contain a reference to M, and vice versa. Discuss why this should be avoided.
The last instruction (0; JMP) effects an unconditional jump. Since the C-instruction syntax requires that we always effect some computation, we instruct the ALU to compute 0 (an arbitrary choice), which is ignored.
The programmer can use the A register to select either a data memory location for a subsequent C-instruction involving M, or an instruction memory location for a subsequent C-instruction involving a jump. Thus, to prevent conflicting use of the A register, in well-written programs a C-instruction that may cause a jump (i.e., with some non-zero j bits) should not contain a reference to M, and vice versa.

Computers and Technology
1 answer:
kati45 [8]2 years ago
4 0

Answer:

To avoid conflicting uses of A register, few well-written programs follow the best practice, i.e, avoiding reference to M and vice versa. The programmer can use the A register to select either a data memory location for a subsequent C-instruction involving M, or an instruction memory location for a subsequent C-instruction involving a jump. Thus, to prevent the conflicting use of the A register, in well-written programs a C-instruction that may cause a jump (i.e., with some non-zero j bits) should not contain a reference to M, and vice versa.

Image is attached for better demonstration and understanding.

You might be interested in
Gloria needs to show in spreadsheet form the number of students in her class who speak different languages. Which type of graph
vaieri [72.5K]
I think the most suitable chart to be used is a pie chart. A pie chart is used to show percentages and the best way to show relative sizes of data in your set. It is a good way to show which language is spoken more in the classroom, which is least spoken and at a glance. I hope my answer helps.
4 0
2 years ago
Wendy is an attacker who recently gained access to a vulnerable web server running Microsoft Windows. What command can she use t
VikaD [51]

Answer:

I would say that if she is connected to the server and has grained access to the server, Wendy would have to use the command shortkey win+r (to run) or she could just use the "Type here to search" function.

Then you can type the words "cmd" to bring up the command prompt

Lastly, she would need to use the protocol scp to transfer files. Wendy might need to include a destination for the files to be directed to.

7 0
1 year ago
Write a while loop that prints userNum divided by 2 (integer division) until reaching 1. Follow each number by a space. Example
jasenka [17]

Answer:

public class Main

{

public static void main(String[] args) {

    int userNum = 40;

    while(userNum > 1){

        userNum /= 2;

        System.out.print(userNum + " ");

    }

}

}

Explanation:

*The code is in Java.

Initialize the userNum

Create a while loop that iterates while userNum is greater than 1. Inside the loop, divide the userNum by 2 and set it as userNum (same as typing userNum = userNum / 2;). Print the userNum

Basically, this loop will iterate until userNum becomes 1. It will keep dividing the userNum by 2 and print this value.

For the values that are smaller than 1 or even for 1, the program outputs nothing (Since the value is not greater than 1, the loop will not be executed).

4 0
2 years ago
A third-grade teacher at Potter Elementary School wants a program that allows a student to enter the amount of money a customer
mina [271]

Answer: IDK

Explanation: ummm I have no idea wut ur asking meh

6 0
1 year ago
how do you make a circuit so 1 switch will turn on/off all the lights(3 lights) and a second switch will change the lights from
expeople1 [14]

Parallel circuit. On a wire you put the lights and one switch, on the other you put a resistor and another switch. (and the third wire contains the generator)
7 0
1 year ago
Read 2 more answers
Other questions:
  • Rob creates a Course_Details table that has four columns: Course _ID, Course_Name, Semester and Credits. A course may have 0.5 c
    6·2 answers
  • What is a typical grace period for a credit card...
    15·2 answers
  • Data is: a. Information endowed with relevance and purpose b. Set of specific objective facts or observations c. Some informatio
    10·1 answer
  • You realize your computer has been infected with malware. It seems as if someone is controlling your computer from a remote loca
    5·1 answer
  • Write a loop that counts the number of space characters in a string. Recall that the space character is represented as ' '.
    11·1 answer
  • Write a function named max that accepts two integer values as arguments and returns the value that is the greater of the two. Fo
    12·1 answer
  • The elements of an integer-valued array can be initialized so that a[i] == i in a recursive fashion as follows: An array of size
    10·1 answer
  • Information systems cannot solve some business problems. Give three examples and explain why technology cannot help.
    11·1 answer
  • Exercise 4: Bring in program grades.cpp and grades.txt from the Lab 10 folder. Fill in the code in bold so that the data is prop
    12·1 answer
  • What is the value of the variable result after these lines of code are executed?
    5·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!