Given the following declarations:

struct house
{
double price;
int rooms;
};
house *ptr1, *ptr2;
which of the following is invalid?

a) ptr1->price = 200000;
b) ptr2->rooms = ptr1->rooms;
c) *ptr1 = ptr2;
d) ptr1 = ptr2;


c) *ptr1 = ptr2;

Computer Science & Information Technology

You might also like to view...

A shallow copy refers to

a. the copying of small objects b. the copying of pointers c. the copying of objects that are being pointed at d. the copying of basic types, such as integers e. call by value

Computer Science & Information Technology

How large is the maximum Ethernet frame, including the CRC?

What will be an ideal response?

Computer Science & Information Technology

Which of the following statements is false?

a. An import statement of the following form enables you to use a module’s definitions via the module’s name and a dot (.): import math b. The following snippet calculates the square root of 900 by calling the math module’s sqrt function, which returns its result as a float value: math.sqrt(900) c. The following snippet calculates the absolute value of -10 by calling the math module’s fabs function, which returns its result as a float value: math.fabs(-10) d. The value of the expression floor(–3.14159) is –3.0.

Computer Science & Information Technology

Round the following values up at the places noted.

16.872 at thousandths place

Computer Science & Information Technology