Are you taking CLEP classes? Try clep.ai
| preferred AP College board partner for AP classes
AP Computer Science A/Unit 1: Primitive Types
Start Practice TestPractice Test
About Exam
medium Solved by 19 students

Integer Division and Type Promotion

Mark
< Prev
Next >

What is printed when the following code segment is executed?

int a = 5;
int b = 2;
double c = 3.0;
System.out.println(5 + a / b * c - 1);
A

0.666666666666667

B

10.0

C

11.5

D

9.0

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
#1zhenmunse11 0m 01s 99
#2songqiuhui201211 0m 05s 95
#3Potter1611 0m 19s 81
#4Wilbert.Ankomah2711 0m 19s 81
#5701704611 0m 26s 74
#6leftoverjluck11 0m 40s 60
#7patrickmeijer00911 0m 42s 58
#8kazvin.tjakradinata11 0m 44s 56
#9y.seong202711 1m 11s 29
#10isaact.taylor5211 1m 16s 24
Items per page:
10
1 – 10 of 18

AI Tutor

How can I help?

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