Choosing how to earn college credit? CLEP vs AP guide
| preferred AP College board partner for AP classes
easy Solved by 4 students

Conditional Logic and Integer Division

Mark
< Prev
Next >

What is printed when the following code segment is executed?

int x = 7;
int y = 3;

if ((x < 10) && (y < 0))
  System.out.println("Value is: " + x * y);
else
  System.out.println("Value is: " + x / y);
A

Value is: 1

B

Value is: 2.3333333

C

Value is: 2

D

Value is: 21

Hint
Did You Know?
Explain Why
Explain All Answers
Check Answer
Show Correct Answer
Report Question

Question Leaderboard

Rank
User
Correct Count
Attempt Count
Total Time
Score
#1ngvandangthanh22 - 200
#2liuwilliam07241011 0m 28s 72
#3171028911 0m 32s 68
#4171662811 0m 55s 45
Items per page:
10
1 – 4 of 4
No comments yet. Be the first to comment!

AI Tutor

How can I help?

APFIVE © 2020.
Email: apfive@apfive.org|Instagram: @_apfive_|Privacy Policy|