C Interview Questions
Questions Answers Views Company eMail

diff. between *p and **p

3 3851

can u suggest me am in a confusion to choose whether to go to c programming or a software testing . am a graduate in B.sc(electronics).

1 1326

what is ANSI and ISO

HCL,

7 3799




what are far pointers?

1 2573

how to swap 2 numbers in a single statement?

2 3001

how to swap 2 numbers within a single statement?

4 4453

i have a written test for microland please give me test pattern

Microland,

1353

what is the meaning of 'c' language

3 2851




#include void main() { int a [5]; for (i=0; i<=4; i++) printf(“%d” ,a[i]); }

8 3806

Write a program using bitwise operators to invert even bits of a given number.

2 6493

Write a program to find whether the given number is prime or not?

6 7412

Write a program to print the prime numbers from 1 to 100?

7 29814

In C program, at end of the program we will give as "return 0" and "return 1", what they indicate? Is it mandatory to specify them?

5 3189

how to TOGGLE Nth bit of variable in a MACRO

NDS,

1 6651

write a c program to find the square of a 5 digit number and print the result.

Sasken, Accenture, Vimukti Technologies,

5 13950


Post New C Questions






Un-Answered Questions { C }

in iso what are the common technological language?

897


Write a program to replace n bits from the position p of the bit representation of an inputted character x with the one's complement. Method invertBit takes 3 parameters x as input character, p as position and n as the number of positions from p. Replace n bits from pth position in 8 bit character x. Then return the characters by inverting the bits.

2816


c program for searching a student details among 10 student details

911


in ‘C’ language for Matrix Multiplication fails” Introspect the causes for its failure and write down the possible reasons for its failure.

4208


I need previous papers of CSC.......plz help out by posting them.......

935






write a c program to find the sum of five entered numbers using an array named number

885


can we have joblib in a proc ?

898


Stimulate calculator using Switch-case-default statement for two numbers

1700


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.

1092


1) There is a singing competition for children going to be conducted at a local club. Parents have been asked to arrive at least an hour before and register their children’s names with the Program Manager. Whenever a participant registers, the Program Manager has to position the name of the person in a list in alphabet order. Write a program to help the Program Manager do this by placing the name in the right place each time the Program Manger enters a name. 2) the Event Manager has to send participants to the stage to perform in the order in which they registered. Write a program that will help the Event Manager know who to call to the stage to perform. The Logic should be in Data Structures

1985


what will be the output for the following main() { printf("hi" "hello"); }

5128


how many errors in c explain deply

838


All technical questions

713


what is the structure pointer?

895


How to draw the flowchart for structure programs?

6344