✅ The verified answer to this question is available below. Our community-reviewed solutions help you understand the material better.
¿Qué imprime este código?
class X {
int valor = 1;
}
public class Test {
public static void cambiar(X x) {
x.valor = 10;
}
public static void main(String[] args) {
X obj = new X();
cambiar(obj);
System.out.println(obj.valor);
}
}