solutions/The C Programming Language/1.5.c

12 lines
183 B
C
Raw Permalink Normal View History

2024-04-16 19:13:00 -04:00
#include <stdio.h>
// converting fahrenheit to celsius
2024-04-16 19:13:00 -04:00
main()
{
for (int fahr = 300; fahr >= 0; fahr = fahr - 20)
{
printf("%3d %6.1f\n", fahr, (5.0 / 9.0) * (fahr - 32));
}
}