r/code • u/EngineeringAlive9368 • Sep 29 '24
Help Please Need help c++ decimal to binary
I have written a code in c++ and I don't think that any thing is wrong here but still the output is not correct. For example if input is 4 the ans comes 99 if 5 then 100 six then 109
4
Upvotes


View all comments
Show parent comment
2
u/EquivalentFact Sep 29 '24
https://en.cppreference.com/w/c/numeric/math/pow