Follow Our FB Page << CircleMedia.in >> for Daily Laughter. We Post Funny, Viral, Comedy Videos, Memes, Vines...


main()

{

char c;

int i = 456;

clrscr();

c = i;

printf("%d", c);

}

a. 456

b. -456

c. random number

d. none of the above

Answers were Sorted based on User's Feedback



main() { char c; int i = 456; clrscr(); c = i; printf("%d"..

Answer / guest

d) -56

Is This Answer Correct ?    21 Yes 5 No

main() { char c; int i = 456; clrscr(); c = i; printf("%d"..

Answer / satya

ans: -56
explanation:
it mainly focus on integer range
it will prints the output like this
for 1=1
2=2....127=-127,
128=-128,
129=-127....256=0;
similarly
456 means 256+256=512=0;
456-512=-56

Is This Answer Correct ?    10 Yes 2 No

main() { char c; int i = 456; clrscr(); c = i; printf("%d"..

Answer / karthi

d.none of the above

Is This Answer Correct ?    8 Yes 2 No

Post New Answer



More C Code Interview Questions

Write a single line c expression to delete a,b,c from aabbcc

2 Answers   Microsoft,


In a gymnastic competition, scoring is based on the average of all scores given by the judges excluding the maximum and minimum scores. Let the user input the number of judges, after that, input the scores from the judges. Output the average score. Note: In case, more than two judges give the same score and it happens that score is the maximum or minimum then just eliminate two scores. For example, if the number of judges is 5 and all of them give 10 points each. Then the maximum and minimum score is 10. So the computation would be 10+10+10, this time. The output should be 10 because 30/3 is 10.

0 Answers   TCS,


How do you verify if the two sentences/phrases input is an anagram using predefined functions in string.h and by using arrays?

0 Answers  


main() { int i =10, j = 20; clrscr(); printf("%d, %d, ", j-- , --i); printf("%d, %d ", j++ , ++i); } a. 20, 10, 20, 10 b. 20, 9, 20, 10 c. 20, 9, 19, 10 d. 19, 9, 20, 10

4 Answers   HCL,


Declare an array of N pointers to functions returning pointers to functions returning pointers to characters?

1 Answers  






main ( ) { static char *s[ ] = {“black”, “white”, “yellow”, “violet”}; char **ptr[ ] = {s+3, s+2, s+1, s}, ***p; p = ptr; **++p; printf(“%s”,*--*++p + 3); }

1 Answers  


Write a Program that Inputs 10 Numbers in an Array and Show the Maximum Number

2 Answers   Ace Info,


How to reverse a String without using C functions ?

33 Answers   Matrix, TCS, Wipro,


main() { float me = 1.1; double you = 1.1; if(me==you) printf("I love U"); else printf("I hate U"); }

1 Answers  


how can i cast a char type array to an int type array

2 Answers  


How we print the table of 3 using for loop in c programing?

7 Answers  


Is the following code legal? void main() { typedef struct a aType; aType someVariable; struct a { int x; aType *b; }; }

1 Answers  






Categories