C - Write program to display integer and float values using the printf() function

Requirements

Display the following values by using the printf() function.

127 
3.1415926535 
12345 
0.00008 

Hint

Use the appropriate conversion characters, either %d or %f.

Demo

#include <stdio.h>

int main()//w w  w .j  a  v  a2 s  .  c  o m
{
    printf("%d\n",127);
    printf("%f\n",3.1415926535);
    printf("%d\n",12345);
    printf("%f\n",0.00008);
    return(0);
}

Result

Related Exercise