Is the below things valid & where it will be stored in
memory layout ?
static const volatile int i;
register struct { } ;
static register;
Answers were Sorted based on User's Feedback
Answer / guest
1.static const volatile int i;
is valid cos it is possible to declare a variable with
multiple qualifiers.
2.register struct a{ } ; is invalid but it will be valid
when u doesnt have body of the structure.
ie., struct a;
3.static register int i; is also invalid cos, here
different storage classes are assigned to a single
variable.
Is This Answer Correct ? | 5 Yes | 0 No |
Answer / banavathvishnu
register struct test
{
int i;
char c;
float f;
};
int main()
{
struct test t;
t.c = 'v';
printf("%c",t.c);
getch();
}
The above code is valid
The below code is invalid
register struct test
{
};
int main()
{
struct test t;
t.c = 'v';
printf("%c",t.c);
getch();
}
Is This Answer Correct ? | 0 Yes | 2 No |
52.write a “Hello World” program in “c” without using a semicolon? 53.Give a method to count the number of ones in a 32 bit number? 54.write a program that print itself even if the source file is deleted? 55.Given an unsigned integer, find if the number is power of 2?
Function which gives a pointer to a binary trees const an integer value at each code, return function of all the nodes in binary tree.?
How do you define a string?
An organised method of depicting the use of an area of computer memory used to signify the uses for different parts of the memory a) swap b) extended memory c) memory map d) all of the above
Explain bit masking in c?
how to get starting address of a running C program
in case any function return float value we must declare a) the function must be declared as 'float' in main() as well b) the function automatically returned float values c) function before declared 'float' keyword d) all the above
What is #line in c?
int main() { Int n=20,i; For(i=0;i<=n;i--) { Printf(“-“); Return 0;
What are bitwise shift operators in c programming?
what is the output of below code int x=8,y; x>>=2; y=x; what is y value. NOTE:EXPLANATION IS COMPALSARY with binary bits
What is a buffer in c?