Question: 1) public class It { private int myX; public It() { myX = 99; } public int getX() { return myX; } public String toString()

1)

public class It { private int myX; public It() { myX = 99; }

public int getX() { return myX; }

public String toString() { return "" + getX(); } }

Question 1 options:

0

1

2

3

4

3)

What is output by the code below? System.out.printf(“%.3f“,9.3213);

Question 3 options:

9.3213

9.321

9.32

9.3

27

6)

What is the output by the code below? System.out.print("a\tc" );

Question 6 options:

a\tc

a c

atc

a\c

ac

10)

What is the output by the code below? int x = 9; double y = x; System.out.println(y);

Question 10 options:

9

9.0

0

There is no output due to a syntax error.

There is no output due to a runtime error.

15)

Which of the following is a 32 bit data type?

Question 15 options:

int

double

long

char

short

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!