what would be the output of the following prog? Justify
your answer?
main()
{
unsigned char ch;
unsigned char i;
ch = -255;
printf("%d",ch);
i = -1;
printf("%d",i);
}
Answer / bittu
1255
this is because -255 (00000001) when considered unsigned
looks like 1(00000001) in binary and -1(11111111) when
considered unsigned looks like 255(11111111) in binary
(11111111).
refer to this
http://www.allaboutcircuits.com/vol_4/chpt_2/3.html
| Is This Answer Correct ? | 5 Yes | 0 No |
can we write a program in c for printf and scanf without using header file stdio.h
what is the difference between : func (int list[], ...) or func (int *list , ....) - what is the difference if list is an array and if also if list is a pointer
What are pragmas and what are they good for?
What are the valid places to have keyword “break”?
please give me a VIRTUSA sample palcement papers.... you will only send TECHNICAL SECTION..... that is help for me Advance Thanks........................
Write a C Program to display the following menu: Menu 1. Display 2. Copy 3. Append 4. Exit Accept the choice (1-4) from the user, and perform the following tasks: Choice 1: Accept a file name from the user and display the file on screen Choice 2: Accept two file names, and copy first file to the second Choice 3: Accept two file names, and append second file to the first file Choice 4: Terminate the program
1 Answers Accenture, Concor, DMU, Satyam, Syntel, Tora,
Explain the advantages of using macro in c language?
Explain how can I make sure that my program is the only one accessing a file?
What is a #include preprocessor?
Is main() function predfined or userdefined?
What is meant by inheritance?
hello freinds next week my interview in reliance,nybody has an idea about it intervew questions..so tell