MIPI_BaseC_WebinarFRTK/16_Seminar03/00_assign_p3.c

15 lines
222 B
C
Raw Normal View History

2024-11-13 09:22:28 +03:00
#include <stdio.h>
int main(void)
{
float f=123.767;
int k, fint;
fint = f; //fint = 123
fint *= 10; //fint = 1230
f = f*10; //f = 1235.67
k = f - fint; //k=5
printf ("%d",k);
return 0;
}