| Computing.Net: Over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to sign up now, it's free! |
What does >>>= mean?
|
Original Message
|
Name: David8F
Date: December 17, 2007 at 12:50:27 Pacific
Subject: What does >>>= mean?OS: Win MXCPU/Ram: P4 3.2Ghz, 1GB RAM |
Comment: Hello, This has been troubling me for a while and I can't find an answer to it because search engines don't understand, but what does the following do/mean in Java? int length >>>= 3; I know that >>> is an unsigned bit shift right, correct? but that equals sign does something that's not an assignment. Secondly, how can I take that line and convert it to C# code? Thanks
Report Offensive Message For Removal
|
|
Response Number 1
|
Name: David8F
Date: December 17, 2007 at 13:24:24 Pacific
|
Reply: (edit)After realizing that "assign" could be included in a search I found the following page: http://www.cafeaulait.org/course/we... So it is a unsigned right shift and assignment. Also there is no such thing in c#, rather the regular shift, <<, performed on a uInt will have the same result as <<< on a normal int in Java. Can someone confirm all this? Thanks!
Report Offensive Follow Up For Removal
|
|
Response Number 2
|
Name: klint
Date: December 17, 2007 at 15:11:31 Pacific
|
Reply: (edit)Yes, I can confirm it, but I assume you mean >>, not <<. (There is no <<< in Java, only a >>>.) In Java, the >>> is needed because all integers are signed. C# has unsigned integers, so no need for >>>.
Report Offensive Follow Up For Removal
|

Post Locked
This post is quite old and has been locked from receiving new replies. Please create a new posting instead.
Go to Programming Forum Home