What is the result? Given: What is the result? Given: What is the result? A. a, e i, o B. a, e o, o C. e, e I, o D. e, e o, o Show Hint ← Previous question Next question →
Ryan Question… public class Vowel { private char var; public static void main (String[] args) { char var1 = ‘a’; char var2 = var1; var2 = ‘e’; Vowel obj1 = new Vowel(); Vowel obj2 = obj1; obj1.var = ‘i’; obj2.var = ‘o’; System.out.println(var1 + “, ” + var2); System.out.print(obj1.var + “, ” + obj2.var); } } Answer… B Reply
Question…
public class Vowel {
private char var;
public static void main (String[] args) {
char var1 = ‘a’;
char var2 = var1;
var2 = ‘e’;
Vowel obj1 = new Vowel();
Vowel obj2 = obj1;
obj1.var = ‘i’;
obj2.var = ‘o’;
System.out.println(var1 + “, ” + var2);
System.out.print(obj1.var + “, ” + obj2.var);
}
}
Answer…
B
Answer
B