Hello,
Im not sure why but when I run my program using v=4/3*PI*pow(r,3); the output appears to disregard the "4/3", but if I use v=1.333333333*PI*pow?(r,3); it gives me the correct answer. Why is that?
When you divide two integers, the result will also be an integer. So 4/3 results in 1.
If at least one operand is a floating point number, the other one will be automatically converted: 4/3.0