wayground logo

Free Printable Worksheets

Font size

S
M
L
XL
Worksheets

CodeHS 5.9 Binary

Total questions: 10

Worksheet time: 8mins

Name
Class
Date
1.

Using eight bits, write the decimal number 132 in binary.

(a)  

2.

Write the binary number 00110110 in decimal

(a)  

3.

Write the lowest possible value for an int in any version of Java

(a)  

4.

Write the highest possible value for an int in any version Java

(a)  

5.

What happens in Java when an integer variable is incremented higher than the highest possible int?

a)

it wraps around to the lowest possible int

b)

it stops at the maximum value

c)

it is converted to a long by late binding

d)

it is converted to a double by late binding

e)

Chef Brian gives you free lunch

6.

What happens in Java when an integer variable is decremented lower than the lowest possible int?

a)

it wraps around to the highest possible int

b)

it stops at the minimum value

c)

it is converted to a long by late binding

d)

it is converted to a double by late binding

e)

Mr. Borowski eats your lunch

7.

Which of these are hexadecimal digits?

a)

F

b)

G

c)

6

d)

0

e)

H

8.
Convert FF Hexadecimal into Decimal
a)
255
b)
15
c)
30
d)
128
9.

What is the decimal number 12 in octal?

(a)  

10.

What is the decimal equivalent of the binary number 1111?

a)

7

b)

8

c)

9

d)

15