Lesson 14.Binary, hex, and octal similarities Decimal, base 10 10 10 eight bits byte mb Store an octal number: 7475 oct I int int base conversion using parseInt: String int Integer.parse("3w4br", 35) a technique for converting 147 from decimal to binary: 10010011 bin = 147 dec a trick for converting 3741 from decimal
Lesson 14.Binary, hex, and octal similarities Decimal, base 10 10 10 eight bits byte mb Store an octal number: 7475 oct I int int base conversion using parseInt: String int Integer.parse("3w4br", 35) a technique for converting 147 from decimal to binary: 10010011 bin = 147 dec a trick for converting 3741 from decimal
Lesson 14.Binary, hex, and octal similarities Decimal, base 10 10 10 eight bits byte mb Store an octal number: 7475 oct I int int base conversion using parseInt: String int Integer.parse("3w4br", 35) a technique for converting 147 from decimal to binary: 10010011 bin = 147 dec a trick for converting 3741 from decimal
the leading 0 indicates octal format Convert an integer variable to a hex String: f3d hex Convert an integer variable to a binary String: 111100111101 bin Convert an integer variable to an octal String: 7475 oct
int
int
Base conversion using parseInt:
String
int
Integer.parseInt(3w4br, 35) A technique for converting 147 from decimal to binary:
10010011 bin = 147 dec
A technique for converting 3741 from decimal to hex: