Multiple Choice
What is the value of ans after the following code has been executed? int x = 40;
Int y = 40;
Int ans = 0;
If (x = y)
Ans = x + 10;
A) 50
B) 80
C) 30
D) No value,this is a syntax error.
Correct Answer:

Verified
Correct Answer:
Verified
Related Questions
Q1: Which of the following correctly tests the
Q4: What will be the value of x
Q6: What would be the value of discountRate
Q10: What will be the values of ans,x,and
Q11: What will be the values of ans,x,and
Q12: What would be the value of bonus
Q20: What will be the value of pay
Q39: If chr is a character variable, which
Q43: The if-else statement will execute one group
Q57: This is a boolean variable that signals