ALLInterview.com :: Home Page KalAajKal.com
 Advertise your Business Here     
Browse  |   Placement Papers  |   Company  |   Code Snippets  |   Certifications  |   Visa Questions
Post Question  |   Post Answer  |   My Panel  |   Search  |   Articles  |   Topics  |   ERRORS new
   Refer this Site  Refer This Site to Your Friends  Site Map  Bookmark this Site  Set it as your HomePage  Contact Us     Login  |  Sign Up                      
info       Did you received any Funny E-Mails from your Friends and like to share with rest of our friends? Yeah!! you can post that stuff   HERE
Google
 
Categories  >>  Software  >>  Programming Languages  >>  C
 
 


 

 
 C interview questions  C Interview Questions
 C++ interview questions  C++ Interview Questions
 VC++ interview questions  VC++ Interview Questions
 Delphi interview questions  Delphi Interview Questions
 Programming Languages AllOther interview questions  Programming Languages AllOther Interview Questions
Question
char ch="{'H','I',0};printf("%s",ch);what is output
 Question Submitted By :: Sandipan
I also faced this Question!!     Rank Answer Posted By  
 
  Re: char ch="{'H','I',0};printf("%s",ch);what is output
Answer
# 1
thats error
 
Is This Answer Correct ?    0 Yes 0 No
Prasath
 
  Re: char ch="{'H','I',0};printf("%s",ch);what is output
Answer
# 2
segmentation fault
 
Is This Answer Correct ?    1 Yes 0 No
Reddy
 
 
 
  Re: char ch="{'H','I',0};printf("%s",ch);what is output
Answer
# 3
error
 
Is This Answer Correct ?    0 Yes 0 No
Punith
 
  Re: char ch="{'H','I',0};printf("%s",ch);what is output
Answer
# 4
h
 
Is This Answer Correct ?    0 Yes 0 No
Vijay
 
  Re: char ch="{'H','I',0};printf("%s",ch);what is output
Answer
# 5
There will be no output
because,in char function the total values should be given
in invited comas i.e,

      ch={"H,I,O"};
 
Is This Answer Correct ?    0 Yes 0 No
Kalpana.y
 
  Re: char ch="{'H','I',0};printf("%s",ch);what is output
Answer
# 6
Hi All,

this is sathish.  upto my knwowledge it depends on 
compiler.  in TurboC  if u give char ch={'AB'};  it will 
print B.   In VC++ if u give char ch={'ABC'} it will give 
C.  But in TurboC u cannot give like this char ch={'ABC'}; 
(three character r nt allowed).
 
Is This Answer Correct ?    0 Yes 0 No
Sathish Kumar
 
  Re: char ch="{'H','I',0};printf("%s",ch);what is output
Answer
# 7
it will print hi...
 
Is This Answer Correct ?    0 Yes 0 No
Vignesh1988i
 
  Re: char ch="{'H','I',0};printf("%s",ch);what is output
Answer
# 8
it gives an error becoz of " .
if we ignore him then o/p will be HI .
 
Is This Answer Correct ?    0 Yes 0 No
Vaibhav
 
  Re: char ch="{'H','I',0};printf("%s",ch);what is output
Answer
# 9
first of all the character initilization itself will give an error. since 0 is not provided with single codes. if we neglect that error or we correct the above error. the final output will be 0
 
Is This Answer Correct ?    0 Yes 0 No
Vignesh1988i
 

 
 
 
Other C Interview Questions
 
  Question Asked @ Answers
 
sqrt(x+sqrt(x+sqrt(x+sqrt(x))))=2; Find the value of x? Subex2
How do I declare an array of N pointers to functions returning pointers to functions returning pointers to characters?  1
difference between semaphores and mutex?  1
what is the diff b/w static and non static variables in C. Give some examples plz. Wipro2
print the following using nested for loop. 5 4 3 2 1 1 2 3 4 3 2 1 1 2 1 2 1 1 2 3 4 3 2 1 1 2 3 4 5  5
What's wrong with "char *p; *p = malloc(10);"?  5
What is structure padding ? HP2
what is use of loop? Infosys6
Which of the following sorts is quickest when sorting the following set: 1 2 3 5 4 1) Quick Sort 2) Bubble Sort 3) Merge Sort  5
what is meant by the "equivalence of pointers and arrays" in C? Satyam3
how do u find out the number of 1's in the binary representation of a decimal number without converting it into binary(i mean without dividing by 2 and finding out the remainder)? three lines of c code s there it seems...can anyone help  2
write a program that finds the factorial of a number using recursion?  1
hello friends what do u mean by BUS ERROR i got this error while i am doing my program in DATA STRUCTURES Wipro2
main() { int i=1; while (i<=5) { printf("%d",i); if (i>2) goto here; i++; } } fun() { here: printf("PP"); } ME3
what is the output of the following program? #include<stdio.h> void main() { int x=4,y=3,z; z=x-- -y; printf("\n%d %d %d",x,y,z); }  10
1,4,8,13,21,30,36,45,54,63,73,?,?. Franklin-Templeton5
I have an array of 100 elements, each of which is a random integer. I want to know which of the elements: a) are multiples of 2 b) are multiples of 2 AND 5 c) have a remainder of 3 when divided by 7  1
How to swap two values using a single variable ? condition: Not to use Array and Pointer ?  4
Who had beaten up hooligan "CHAKULI" in his early college days?  1
#include main() { int i=1,j=2; switch(i) { case 1: printf("GOOD"); break; case j: printf("BAD"); break; } } ME5
 
For more C Interview Questions Click Here 
 
 
 
 
 
   
Copyright Policy  |  Terms of Service  |  Help  |  Site Map 1  |  Articles  |  Site Map  |   Site Map  |  Contact Us interview questions urls   External Links 
   
Copyright © 2007  ALLInterview.com.  All Rights Reserved.

ALLInterview.com   ::  Forum9.com   ::  KalAajKal.com