Question: 1. Write C code to do the following: a. Declare an integer (named a) and a pointer to an integer (named b) b. Assign the

1. Write C code to do the following:

a. Declare an integer (named a) and a pointer to an integer (named b)

b. Assign the pointer to point to the integer

c. Increment the integer by using the pointer.

2. Write C code to do the following:

a. Declare both an integer and a pointer to an integer

b. Set the pointer equal to memory location 0x80001800.

c. Read contents of the memory location (by using the pointer) into the integer you declared.

d. Then set the pointer equal to memory location 0x8000180C.

e. If the least significant bit of the memory location you read is 1, set the contents of memory location 0x8000180C to 0. If the least significant bit is 0, set the contents of the memory location to 0x1FF.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!