![]() |
|
#1
|
||||
|
||||
Rotate bits!!hey frenz
I'm looking for an efficient code for rotating bits using >> and << operators.. ( not just shift but rotate!!) Cud u help!! thnx Bharani |
|
#2
|
|||
|
|||
Re: Rotate bits!!Maybe something like this:
CPP / C++ / C Code:
|
|
#3
|
|||
|
|||
Re: Rotate bits!!Quote:
CPP / C++ / C Code:
Output for a few values: Code:
Regards, Dave Regards, Dave |
|
#4
|
|||
|
|||
Re: Rotate bits!!Whoops, the example I gave was for reversing bits. Sorry.
|
|
#5
|
|||
|
|||
Re: Rotate bits!!Quote:
Regards, Dave |
|
#6
|
||||
|
||||
Re: Rotate bits!!hey,,,
thnx |
Recent GIDBlog
2nd Week of IA Training by crystalattice
| Thread Tools | Search this Thread |
| Rate This Thread | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| BMP image on matrix load | nemo | CPP / C++ Forum | 21 | 17-Dec-2007 23:04 |
| Rotate Array | cable_guy_67 | CPP / C++ Forum | 2 | 11-Jun-2007 06:21 |
| Binary number systems: BCD, twos complement, ones complement, etc. | machinated | Miscellaneous Programming Forum | 6 | 08-Feb-2006 10:51 |
| link error? | pablowablo | CPP / C++ Forum | 14 | 19-Jun-2004 10:00 |
| problems typecasting an int to a string | holbrook | CPP / C++ Forum | 9 | 07-May-2004 18:59 |
Network Sites: GIDNetwork · GIDWebHosts · GIDSearch · Learning Journal by J de Silva, The