C Interview Questions
Questions Answers Views Company eMail

WRITE A PROGRAM TO MERGE TWO SORTED ARRAY USING MERGE SORT TECHNIQUE..

773

#include #include int main() { int a[4][4]={{5,7,5,9}, {4,6,3,1}, {2,9,0,6}}; int *p; int (*q)[4]; p=(int*)a; q=a; printf("\n%u%u",p,q); p++; q++; printf("\n%u%u",p,q); getch(); return 0; } what is the meaning of this program?

2 2090

what is void pointer?

Wipro,

1 2456




1234554321 1234 4321 123 321 12 21 1 1 12 21 123 321 1234 4321 1234554321

1919

void main() { int a=1; while(a++<=1) while(a++<=2); }

HCL,

4 3610

The postoder traversal is 7,14,3,55,22,5,17 Then ur Inorder traversal is??? please help me on this

1 1771

being a chemical engineer and with an aggregate of 80% why you opt for TCS and not your core industry?

TCS,

1 2545

write a program for egyptian fractions in c?

Satyam,

1 4930




How to write the code of the program to swap two numbers with in one statement?

2 3652

write a program to display & create a rational number

TCS, HCL,

1 2522

who developed c and why he developed c?

5 7915

WHO WROTE C LANGUAGE?

4 4709

WHAT IS C?

6 2501

WHAT IS LOW LEVEL LANGUAGE?

2 1728

WHAT IS HIGH LEVEL LANGUAGE?

2 2199


Post New C Questions






Un-Answered Questions { C }

Create a structure to specify data on students given below: Roll number, Name, Department, Course, Year of joining Assume that there are not more than 450 students in the college. 1.write a function to print names of all students who joined in a particular year 2.write a function to print the data of a student whose roll number is given

918


Write a program to compute the similarity between two strings - The program should get the two strings as input - Then it will output one single number which is the percentage of similarity between the two strings

1470


develop a breakfast order booking system using Functions, Structures and Arrays. The system is to support the operations shown to the user in the following system’s menu: Welcome to Asim's Restaurant Select an operation? 1 Make a breakfast order 2 Modify existing order 3 Cancel existing order 4 Print Bill 5 Exit Type in your selection (1, 2, 3, 4 or 5): The program will include an array of structures. The structure type is called MenuItem, and the array of structures should be declared as menu[50] to store upto 50 breakfast menu items. The MenuItem structure must have the following 4 data fields (i.e. members): Code, description, unitprice, and quantity. Your program must define at least the following functions:  Function LoadData(…) that loads the data of breakfast menu items from an input file menu.txt into the array menu.  Five separate functions to handle the program main menu five tasks shown above. In general, function main() should load the data into the array menu and display the main menu of the above mentioned tasks. Based on the option selected, the corresponding function should be called. Users must make an order before requesting modify, cancel or print order bill (See the given sample run). Here is a more detailed explanation on the above tasks and functions. LoadData(…) Opens the input file menu.txt (you will create it) containing breakfast menu items data (See below) and assign these values to the corresponding array menu structure fields. Assign zero to the quantity field of the loaded menu items. Welcome to Asim's Restaurant Select an operation? 1 Make a breakfast order 2 Modify existing order 3 Cancel existing order 4 Print Bill 5 Exit Type in your selection (1, 2, 3, 4 or 5): MakeOrder(…) This function is called when the user selects option 1 from the main menu. It first displays the breakfast menu items to the user (stored in the array menu) along with all the necessary information (item code, description and unit price). It then requests the user to select an item using the item code (see the sample run). When the user enters an item code number the program should verify the code number and increment the quantity of the selected item in the array menu. Your program should reject invalid item codes and request the user to re-enter the item code or stop the entry. PrintBill(…) This function is called when the user selects option 4 from the main menu. The function displays the breakfast menu items in the breakfast order by printing the values of all MenuItem members of the array menu that have quantity value above zero. Print a nicely formatted bill (See the sample run). CancelOrder(…) This function is called when the user selects option 3 from the main menu. It will cancel the breakfast order by setting the quantity value of all the array menu structures to zero. ModifyOrder(….) This function is called when the user selects option 2 from the main menu. The task of this function is to allow the user to edit an existing breakfast order with two operations: Adding more breakfast items and/or altering the breakfast item that were ordered before (examine the sample program run). Handling Errors and Invalid Input Your program should reply safely to any erroneous situation or input with appropriate message to the user and flow nicely and correctly to the next operation (Examine the sample program run). Additional functions Use of functions is highly recommended for any additional special tasks needed by your solution. Global variables are not allowed except for max array menu size 50. You must pass the needed parameters through functions parameter lists.

1093


how could explain about job profile

703


Hai sir, I had planned to write the NIC scientific engineer exam , plz post the sample question......

785






write a program for the normal snake games find in most of the mobiles.

1080


List at least 10 sorting methods indicating their average case complexity, worst case complexity and best case complexity.

1447


How do we make a global variable accessible across files? Explain the extern keyword?

653


Write a program to generate a pulse width frequency of your choise,which can be variable by using the digital port of your processor

2065


I was asked to write a program in c which when executed displays how many no.of clients are connected to the server.

1107


I completed my B.tech (IT). Actually I want to develop virtual object that which will change software technology in the future. To develop virtual object what course I have to take. can I any professor to help me.

952


how many errors in c explain deply

839


Write the test cases for checking a variable having value in range -10.0 to +10.0?

902


WHAT IS THE DEFINATION OF IN TECHNOLOGY AND OFF TECHNOLOGY ?

1071


write a program which the o/p should b in such a way that s triangle if I/p is 3,a Square/rectangle if I/P=4,a pentagon if I/P=5 and so on...forget about the I/P which is less than 3

860