Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR C

c float to string

#include <stdio.h>
int main()
{
   float f = 1.123456789;
   char c[50]; //size of the number
    sprintf(c, "%g", f);
    printf(c);
    printf("
");
}
 
PREVIOUS NEXT
Tagged: #float #string
ADD COMMENT
Topic
Name
5+3 =