Opinion 1:
How do you create a new
Point Object?
- Point p = Point(3,2);
- Point p(3,2);
- p=Point(3,2);
- Point p = Point::Point(3,2);
- Point p = new Point(3,2);
Question 2:
Consider the following code snippet
int x = 7;
int y = 11;
Point p(3,2);
p.setX(y);
p.print();
What is the output of this program?
- (3, 11)
- (7, 11)
- (11, 2)
- (3, 2)
- This will generate an error
Question 3:
On the pointer worksheet what are the
values of
*p and
*q?
- 40 and 40
- 40 and 0x80
- 0x80 and 0x7b
- 0x78 and 0x70
- This will generate an error
Question 4:
On the pointer worksheet what are the
values of
a and
b after the increments?
- 40 and 40
- 41 and 40
- 42 and 40
- 42 and 42
- This will generate an error
Question 5:
On the pointer worksheet what are the
values of
a and
b after the increments?
- 42 and 40
- 42 and 41
- 42 and 42
- 43 and 40
- This will generate an error