Java assigning using operators.

0 moki toki · June 7, 2014
Ok so I have recently come upon some weird code that I could not understand neither find out the answer for:


int x = 7 & 5;


So what I came upon wasn't this exactly but this sort of thing where your assigning a value with using the & operator. Also I tried doing this and it worked:


int x = 6  5;


I got a result but I have absolutely no idea what it means. Could someone explain?

Post a Reply

Replies

Oldest  Newest  Rating
-1 Jay Deshaun · June 8, 2014
I somewhat know about this but I would suggest you read more about it here: http://en.wikipedia.org/wiki/Bitwise_operation#AND
+1 moki toki · June 7, 2014
What does that even mean?
  • 1

Java / Android Development

107,224 followers
About

Very popular language used to create desktop applications, website applets, and Android apps.

Links
Moderators
Bucky Roberts Administrator