Bugfix for a spin caused by setting the value of fahr inside the for loop when it is now initialized at loop start.
This commit is contained in:
parent
61e32d0e22
commit
fc658ddb69
2 changed files with 1 additions and 2 deletions
|
|
@ -13,7 +13,6 @@ int main(){
|
||||||
printf("%4s\t%6s\n", "DegF", "DegC");
|
printf("%4s\t%6s\n", "DegF", "DegC");
|
||||||
|
|
||||||
for (float fahr = lower; fahr <=300; fahr = fahr + step){
|
for (float fahr = lower; fahr <=300; fahr = fahr + step){
|
||||||
fahr = lower;
|
|
||||||
printf("%4.0f\t%6.1f\n", fahr, (5.0/9.0)*(fahr-32));
|
printf("%4.0f\t%6.1f\n", fahr, (5.0/9.0)*(fahr-32));
|
||||||
}
|
}
|
||||||
return 0;
|
return 0;
|
||||||
|
|
|
||||||
BIN
KNR C/ex1_1.out
BIN
KNR C/ex1_1.out
Binary file not shown.
Loading…
Add table
Add a link
Reference in a new issue