-
Header File
Why should we use header file?
-
Hello World
Write a program in C to display output as "hello world" without using semicolon(;)?
-
Call a Function
How to call a function, given its name as a string?
-
Return Multiple Values from Function
How to return multiple values from a function?
-
Allocate Arrays or Structures
How to allocate arrays or structures bigger than 64K?
-
Write sample code or algorithim to get all possible combinations of data that will be entered from keyboard
like, If i enter 1 2 3 then it should show 1 2 31 3 2 2 1 3 All 6 possible combnations
-
-
-
If the program (myprog) is run from the command line as myprog 1 2 3 , What would be the output? main(int argc, char *argv[]) { int i; for(i=0;i<argc;i++) printf("%s",argv[i]); }
A) 1 2 3B) C:MYPROG.EXE123C) MYPD) None of the above
-
TSR
Explain How Terminate & Stay Resident (TSR) and Offline programming differ from one another.
-
-
-
Execute Shell Command
How will you execute shell command without using system command in C-language? Write a program to execute ls -l and redirect the output to a file, without using system command ?
-
-
Image in C Program Console
How to put Image in C Program Console
-
-
-
-
Given the values of two nodes in a *binary search tree*, write a cprogram to find the lowest common ancestor. You may assume that bothvalues already exist in the tree.The function prototype is as follows:int FindLowestCommonAncestor(node* root,int value1,int value) 20 / 8 22 / 4 12 / 10 14I/P : 4 and 14O/P : 8(Here the common ancestors of 4 and 14, are {8,20}. Of {8,20}, the lowest one is 8).
One of the solution can be to find out postorder traversal taking each node one by one. This postorder function should return true if both the values (v1 & v2) are found in the postorder traversal of the given node. NOTE: The given tree is a BST.... think over it......
-
C Interview Questions
Ans