TOPUPchat logo...
Forgot password?

Select : C language | Java

Q.9] Assigning auto variable to static variable

void main(){
  int i=10;
  static int x=i;
  if(x==i)
     printf("Less than");
  else if(x>i)
     printf("Greater than");
  else
     printf("Equal");
}
    

Options]

(a) Equal
(b) Greater than
(c) Less than
(d) Compiler error
(e) Runtime Error        

Click to See Answer
(d) Compiler error    

Next | comparision between float variable and 0.7 constant

Previous | For given compiler sizeof(int)=4 (like “dev c++” compiler)

Hemen Ashodia [paper setter]
Register & recharge
Male Female
I agree Terms and Conditions