Share on Google+Share on Google+

Binary Literals

In this section, you will learn about representing integral types with the help of binary number system which is the one of the added feature in Java SE 7


Posted on: September 3, 2011 If you enjoyed this post then why not add us on Google+? Add us to your Circles

Share this Tutorial Follow us on Twitter, or add us on Facebook or Google Plus to keep you updated with the recent trends of Java and other open source platforms.

Discuss: Binary Literals  

Post your Comment

Your Name (*) :
Your Email :
Subject (*):
Your Comment (*):
  Reload Image
September 17, 2011

how do use your website?
December 12, 2011
Binary Literals

Arshad khan
January 7, 2012
Binary literal

Java code, due to its C heritage, has traditionally forced programmers to represent numbers in only decimal, octal, or hexadecimal. As quite a few domains are bit orientated, this restriction can introduce errors. You can now create binary numbers using an 0b prefix. int binary = 0b1001_1001; just like that.