Home

The output of the following code is:
void change (char *k) 
{
k="Hello";
return;
}
main()
{
char *ch = "World";;
change(ch);
printf("%s", ch);
}

A. Hello

B. World

C. Compilation error

D. Hello World

You can do it
  1. fprintf()function can be used to write into console.
  2. printf("%d", sizeof('2')); will print 2.
  3. Which of the following is not true about preprocessor directives
  4. The output of the following code is: void main(){int z, a = 5, b = 3; z = a * 2 + 26 % 3;printf("%d",…
  5. Expression 4**3 evaluates to 64.
  6. The identifier argv[] is a pointer to an array of strings.
  7. Which options shows the correct hierarchy of arithmetic operators
  8. do-while loop is useful when we want the statements within the loop must be executed
  9. Which of the following is not recommended in a header file?
  10. A pointer is an indication of the variable to be accessed next.
  11. What is the right way to access value of structure variable book{ price, page }?
  12. gets() and puts() are unformatted I/O functions.
  13. The output of the following code is: main() { void msg() { printf("HELLO WORLD"); } }
  14. The output of the following code is: main() { xyz: goto abc;printf("Hello"); abc: printf("World");goto…
  15. If 'str' is a string of 7 characters, the statement printf("%4s", str); will display ------characters.
  16. For 16bit compiler allowable range for integer constants is ______ ?
  17. The same variable names of automatic type can be used in different functions without any conflict.
  18. Which of the following correctly describes C++ language?
  19. Variables declared as register storage type gets stored in CPU registers.
  20. C programs are converted into machine language with the help of
  21. The expression (i + j)++ is illegal.
  22. When a user defined function is defined in program, then it has to be called at least once from the…
  23. The output of the following code is: main() { int k, num = 30; k = (num > 5 ? (num <= 10 ? 100…
  24. Which escape character can be used to beep from speaker in C?
  25. Which of the STL containers store the elements contiguously (in adjecent memory locations)?
  26. The output of the following code is: void main() {float a;int x = 10, y = 3; a = x / y;printf("%f",…
  27. The function fopen() on failure returns---------------------.
  28. The output of the following code is: int f(int a, int b); void main() {int a = 12, b=154; printf("%d",…
  29. unsigned char has a range from 0 to ------------
  30. The contents of a file opened in 'r+' mode cannot be changed.