Computer Science, asked by anushatenneti18, 11 months ago

Write a C program to assign 10 to int variable,20.55 to float variable, 'A' to char variable and print them on the console to produce the below given output:
Integer Value = 10
Floating point Value = 20.549999
Character Value = A
Note: Use a newline character (\n) in the printf() function ​

Answers

Answered by sairohit520
6

Answer:

#include<stdio.h>

int main(){

int n=10;

float f=20.55;

char c='A';

printf("Integer Value = %d\n Floating point Value = %f\n Character Value= %c",n,f,c);

return 0;

}

Explanation:

The print statement in the code is the meat of the code at the every end of % operator we're putting \n to print the segment in newline

Similar questions