Java Explained: bit, byte, short, int, long (and how to convert them)

preview_player
Показать описание
In Java, there is no distinction between signed and unsigned bytes, which can be confusing. In this video, I describe the different numeric values in Java with more info and code examples…

Blog post with more descriptions:

Source code used in this video:

Book "Getting Started with Java on the Raspberry Pi":

Binary counter video:

Content

00:00 Introduction
00:36 Different number types in Java
01:10 How to calculate 4 bits to hex
03:30 How to calculate 8 bits to a byte
04:44 MIN and MAX of Byte, Short, Integer, and Long
06:25 Signed versus Unsigned
08:27 Applying a mask to a byte
12:23 Use case: LED Segment Display
13:44 Conclusion
Рекомендации по теме
join shbcf.ru