what will be the output:
main(){char ch;int a=10;printf("%d",ch);}
Answer Posted / lnk
In the above coding ...
there is a char "ch " assigned with out a value
and a int" a " assigned with a value ...
and it compiles to print a interger (%d) ...
but tries to read a int value fronm ch (which does not
match the data type ) so it gives garbage value .with
compile time warning !
| Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
What is calloc malloc realloc in c?
Are local variables initialized to zero by default in c?
write a program to copy the string using switch case?
how to execute a program using if else condition and the output should enter number and the number is odd only...
What type of function is main ()?
Can you please compare array with pointer?
Explain what is the general form of a c program?
Write a C program on Centralized OLTP, Decentralized OLTP using locking mechanism, Semaphore using locking mechanism, Shared memory, message queues, channel of communication, sockets and a simple program on Saving bank application program using OLTP in IPC?
What is the difference between new and malloc functions?
What is indirection? How many levels of pointers can you have?
What are the types of pointers in c?
How can I use a preprocessorif expression to ?
What is a macro in c preprocessor?
write a program that will open the file, count the number of occurences of each word in the the complete works of shakespeare. You will then tabulate this information in another file.
largest Of three Number using without if condition?