Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

We can allocate string literals and global variables in the .data section of an

ID: 3793301 • Letter: W

Question

We can allocate string literals and global variables in the .data section of an assembly language program. Write MARS directives which would allocate the following C-like variables in the .data section. char ch 1 = ' ', ch2 = '$';//Assume char variables/values are 1-byte int x = 0, y = -1, z;//Assume int variables/values are 4-bytes char *name = "Marge Simpson";//name is a label assoc'd with the address of the first char int iarray[250] = {0};//iarray is an array of 250 ints, all initialized to 0 char carray[250] = {0};//carray is an array of 250 chars, all initialized to 0

Explanation / Answer

b)

(c)

(d)

(e)

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote