char* f()
return "hello:";
void main()
{char *str=f();
}



char* f() return "hello:"; void main() {char *str=f(); }..

Answer / parthiban

str will be a pointer to "hello:"

so on printing str will output hello:

Is This Answer Correct ?    3 Yes 2 No

Post New Answer

More C C++ Errors Interview Questions

which typw of errors ? & how to solve it ?

0 Answers  


printy(a=3,a=2)

3 Answers  


UINT i,j; i = j = 0; i = ( i++ > ++j ) ? i++ : i--; explain pls....

5 Answers  


I'm having trouble with coming up with the correct code. Thank You!! The assignment was to write a program using string functions that accepts a price of an item and displays its coded value. The base of the keys: X C O M P U T E R S 0 1 2 3 4 5 6 7 8 9 Sample I/O Dialogue: Enter Price: 489.50 Coded Value: PRS.UX

0 Answers  


how tally is useful?

2 Answers  






Find the error (2.5*2=5) (a) X=y=z=0.5,2.0-5.75 (b) s=15;

3 Answers  


what is syntax error?

3 Answers  


quoroum of computer languages?

0 Answers   Infosys,


Given that two int variables, total and amount, have been declared, write a loop that reads integers into amount and adds all the non-negative values into total. The loop terminates when a value less than 0 is read into amount. Don't forget to initialize total to 0. Instructor's notes: This problem requires either a while or a do-while loop.

3 Answers  


how to convert decimal to binary in c using while loop without using array

50 Answers   Apple, Aptech, Arwen Tech, BCS, C2D Software, CEC,


Write a C program to enter 10 integer numbers through one variable and count how many of them are even using while loop ?

2 Answers  


Write down the difference between c. Loop and goto statement d. (!0) and (!1) e. (1= =! 1) and (1!=1) f. NULL and !NULL

0 Answers  


Categories