Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- for (int i = 0; i < 8; i++)
- {
- fraction *= 8;
- double q = (int)fraction;
- frac_res += q * (1/pow(8,i+1));
- fraction -= q;
- }
- result = int_res + frac_res;
- cout << result;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement