Given:
class Fizz {
int x = 5;
public static void main(String[] args) {
final Fizz f1 = new Fizz();
Fizz f2 = new Fizz();
Fizz f3 = FizzSwitch(f1,f2);
System.out.println((f1 == f3) + " " + (f1.x == f3.x));
}
static Fizz FizzSwitch(Fizz x, Fizz y) {
final Fizz z = x;
z.x = 6;
return z;
} }
What is the result?
发布于 2021-02-15 03:24:28
【单选题】
A true true
B false true
C true false
D false false
查看更多
- 体验AI问答!更聪明、超智能!
- 一款基于GPT的超级AI助手,可以对话、创作、写文案!