Answer to Question #214620 in C for a.s.vijay

Question #214620

Write a C program to print weight and height of a person using typedef.


1
Expert's answer
2021-07-07T01:53:56-0400
#include <stdio.h>  
int main()  
{  
    typedef float f;  
    f height, weight;
    
    printf("Enter your height: ");
    scanf("%f",&height);
    
    printf("Enter your weight: ");
    scanf("%f",&weight);
    
    printf("Height is: %f",height);  
    printf("\nWeight is: %f",weight);  
    
    return 0;  
}  

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be the first!

Leave a comment

LATEST TUTORIALS
New on Blog
APPROVED BY CLIENTS