For reference, I know that the pow=num part is wrong, I was just testing the rest of my program, so I know thats where i need to make a change to calculate the pow of 2.
Long double main - I changed the pow=(num*2); to pow=(pow*2); and it got me a little closer, for example when my input was 6 my number was 8 when it should be 4.
giblit- when you say pow *2<num, i should write it as:
while( (pow*2)) <num)) {
- I cant seem to get the formatting right where it wont give me an error in that situation