what would be the output of the follwing
struct st
{
char name[20];
int i;
float f;
};
main()
{
struct st emp = {"forum"};
printf("%d %f",emp.i,emp.f);
}
Answers were Sorted based on User's Feedback
Answer / maruthi
Answer:0,0
Because if 1 element is initialised in structure or array
the remaining elements are initialised to 0 by default.
Is This Answer Correct ? | 8 Yes | 2 No |
What is dangling pointer in c?
1,1,5,17,61,217,?,?.
WHAT IS LOW LEVEL LANGUAGE?
What are the advantage of c language?
Explain what happens if you free a pointer twice?
Program will then find the largest of three numbers using nested if-else statements. User is prompted to enter three numbers. Program will find the largest number and display it on the screen. All three numbers entered by the user are also displayed. If user enters 21, 33, and 5, the output should be as follows: You entered: 21, 33 and 5. The largest number is 33.
What is preprocessor with example?
Why header file is used in c?
atoi, which takes a string and converts it to an integer. write a program that reads lines(using getline), converts each line to an integer using atoi and computes the average of all the numbers read. also compute the standard deviation
What is difference between && and & in c?
A.C func() { pritnf(" in fuction %d",MACRO); } MAIN.c testfunc() { #define MACRO 10 printf("in test function %d", MACRO); } main() { printf("in main %d",MACRO); func(); testfunc(); getch(); }
If 4 digits number is input through the keyboard, Write a program to calculate sum of its 1st & 4th digit.