Question 17 / 50:  Given the following piece of code:

class Person { public int number; }

public class Test{

public void doIt(int i , Person p){

i = 5;

p.number = 8;

}

public static void main(String args[]){

int x = 0;

Person p = new Person();

new Test().doIt(x, p);

System.out.println(x + " " + p.number);

}

}

A  0 8
B  50
C  00
D  58
<< First < Previous Flashcard Next > Last >>
Quiz Home Page
https://www.jobilize.com/abishek-devaraj-core-java-unit-test-1-caj003

Core Java Unit Test-1(CAJ003)

Author:

Access: Public Instant Grading

Ask
Anindyo Mukhopadhyay
Start Quiz
Tess Armstrong
Start Quiz
Copy and paste the following HTML code into your website or blog.
<iframe src="https://www.jobilize.com/embed/abishek-devaraj-core-java-unit-test-1-caj003" width="600" height="600" frameborder="0" marginwidth="0" marginheight="0" scrolling="yes" style="border:1px solid #CCC; border-width:1px 1px 0; margin-bottom:5px" allowfullscreen webkitallowfullscreen mozallowfullscreen> </iframe>