GetDotted Domains

Viewing Thread:
"C bitwise operators"

The "Freeola Customer Forum" forum, which includes Retro Game Reviews, has been archived and is now read-only. You cannot post here or create a new thread or review on this forum.

Mon 07/01/02 at 13:44
Regular
Posts: 787
right, I need to write a program which removes the the 4 bits from the left of two usigned char variables, then compares the two new variables. The higher number has to have a 1 places in the left most bit, without effecting the numbers in the rest of the variable......

Anyone any ideas on how?
Mon 07/01/02 at 16:43
Regular
"Picking a winner!"
Posts: 8,502
If you have any problems post them in here. I'll do my best to try help a little but not sure if I will be able to offer any help. But i'll try.
Mon 07/01/02 at 16:22
Regular
Posts: 6,492
Hmmm, it's of fixed length because it's an unsigned char, only 8 bits long. the first 4 record the score of the hand, then next two the number of cards, the next one whether or not there was an ace and the last for the winner.

I have all the other things up and running, I just can't get them to compare without altering all the other bits in the number, but it's ok, I have it sussed..............

I think.
Mon 07/01/02 at 16:04
Regular
"Picking a winner!"
Posts: 8,502
Has it to be done using C??

If so it sounds tricky but i would imagine that it is done using pointers.
Mon 07/01/02 at 13:52
Regular
"Pouch Ape"
Posts: 14,499
Have each seperate character as a variable and then make the final variable a combination of the characters. I know what I mean, even if it's not that clear. Is the variable of a fixed length?
Mon 07/01/02 at 13:44
Regular
Posts: 6,492
right, I need to write a program which removes the the 4 bits from the left of two usigned char variables, then compares the two new variables. The higher number has to have a 1 places in the left most bit, without effecting the numbers in the rest of the variable......

Anyone any ideas on how?

Freeola & GetDotted are rated 5 Stars

Check out some of our customer reviews below:

I am delighted.
Brilliant! As usual the careful and intuitive production that Freeola puts into everything it sets out to do. I am delighted.
Brilliant service.
Love it, love it, love it!
Christopher

View More Reviews

Need some help? Give us a call on 01376 55 60 60

Go to Support Centre

It appears you are using an old browser, as such, some parts of the Freeola and Getdotted site will not work as intended. Using the latest version of your browser, or another browser such as Google Chrome, Mozilla Firefox, or Opera will provide a better, safer browsing experience for you.