Very impressive y99q,
Thinking about it the question was way out of scope and context for that chapter in the book!
Thank you though - you proved the difficulty of this and drove me from...
Type: Posts; User: philuk2000
Very impressive y99q,
Thinking about it the question was way out of scope and context for that chapter in the book!
Thank you though - you proved the difficulty of this and drove me from...
:D I have not even got to functions in the book yet - other than main. I think we'll agree that the question in the book is worded badly - I actually think it's more likely asking for 5 raised to...
OK i appreciate your comments. I have written the question exactly as it is in the book and have not missed anything significant that I have communicated here. Earlier in the chapter I had to use <<...
Thanks CommonTater,
I got the book on the recommendation of this site (cprogramming.com) :-) but the question is still valid, although I also questioned to myself if it was a mistake before you...
OK folks! both of you thanks for the info. Let me give a little more background because you both come up with something but I cannot use either.
The exercise is from a C programming book called...
Sorry I made a mistake in the original post
Five to the first power of 2 is 25. Not 5
Five to the second power of 2 is 125. Not 25
I'm assigned a programming task in c where I need to use bitwise operators to raise 5 to the nth power of 2 and i'm struggling a little I cannot use loops or the pow function!
The output needs to...
I found the solution as a FAQ linked below. I should have declared ch as an int not a char.
Question 12.1
Thanks
I am learning C using C for dummies 2nd Edition. I'm using codeblocks 10.05 with mingw (GCC) on Windows 7 Ultimate (64bit).
When I compile and run the code below on Windows XP everything works as...