Will somebody please tell why this doesn't work.... I am passing param by value:
I am getting big numbers, something like 803459439.0 etc....
What's going on here? Can I pass float type number by value?
I also tried this printf("value = %.1f", 5); and I got very big number.... several lines of numbers.... Why?
Thanks in advance....
Code:
float x = myfun();
printf("value = %.1f", x);
.........
float myfun(){
float c = 0.5;
return (c);
}
I am getting big numbers, something like 803459439.0 etc....
What's going on here? Can I pass float type number by value?
I also tried this printf("value = %.1f", 5); and I got very big number.... several lines of numbers.... Why?
Thanks in advance....