What are the values of x and y
int a = 63; b = 36;
boolean x = (a > b) ? true : false;
int y = (a < b) ? a : b;
Answers
Answered by
1
Explanation:
What are the values of x and y
int a = 63; b = 36;
boolean x = (a > b) ? true : false;
int y = (a < b) ? a : b;
Answered by
1
Answer:
x=true
y=36
Explanation:
In Boolean Condition, the condition is true so the value of Boolean x will be true
In condition of y the result of the ternary operator is false so the value of y will be the value of b i.e., 36
Similar questions