Вы находитесь на странице: 1из 6

QUESTION BANK (Sample)

FC3401-PIC
Unit-1 (Program logic development)

2 Marks

1. Define algorithm.
2. State properties of algorithm.
3. State the advantages of using flowchart.
4. State flowchart.
5. Write the symbol for i) Initialization of variable. ii) Start/Stop.
6. Write any four advantages of algorithm.
4 Marks

1. Write the algorithm for determine whether the given number is even.
2. Explain how to write the algorithm with example.
3. Explain the guidelines for preparing flowchart.
4. Write any four symbol of flowchart with its description.
5. Write algorithm to find greatest number among two numbers.
6. Write algorithm to convert Fahrenheit to Celsius.
7. Write algorithm to swap two numbers.
8. Draw flowchart for the given algorithm A : First Side of Triangle B : Second Side of Triangle
C : Third Side of Triangle AREA : Area of Triangle PERIMETER : Perimeter of Triangle
Algorithm

Step-1 Start
Step-2 Input Sides of Triangle A,B,C
Step-3 S= (A + B + C)/ 2.0
Step-4 AREA = SQRT(S x (S-A) x (S-B) x(S-C))
Step-5 PERIMETER = S1 + S2 + S3
Step-6 Display AREA, PERIMETER
Step-7 Stop

9. Draw flowchart for following algorithm where P : Principle Amount


N : Time in Years R : % Annual Rate of Interest CI : Compound Interest
Algorithm
Step-1 Start
Step-2 Input value of P, N, R C
Step-3 CI = P(1+R/100)N - P
Step-4 Display CI
Step-6 Stop
Unit-2 (Basics of C programming)

2 Marks

1. State the header files in basic structure of C program.


2. State the Character set.
3. State the tokens. Enlist any two tokens.
4. State keyword and identifiers.
5. Differentiate between constant and variables.
6. Write syntax to declare a variable.
7. Enlist any four relational operators.
8. Enlist the logical operators.
9. Define data type conversion. Write it’s type.
10. Write syntax of input statement.
4 Marks

1. Explain the basic structure of C program.


2. Explain the various operators in C.
3. Explain the declaration of variables with examples.
4. Explain the relational operators in C.
5. Explain increment operator in C with example.
6. Explain the decrement operator in c with example.
7. Explain output statement with example.
8. Write program using character input/output statement.
9. Write a program to find smallest number among 3 using relational operator.
10. Write a program to display positive (absolute value) number using logical operator.
11. Write a program using assignment operator.

Unit-3 (Control Structure)

2 Marks

1. Write syntax of if-else.


2. Write syntax of nested if-else.
3. Write syntax of if-else ladder.
4. Write syntax of switch case.
5. Write use of break and continue statement.
6. Write syntax of conditional operator.
7. State need of loop statements.
8. Write syntax of do-while loop.
9. Write syntax of for loop.
10. Compare do-while and while loop.(any two point)
4 Marks

1. Find the smallest number among 3 by using the nested if-else.


2. Write a program to find largest among 3 number by using else if ladder.
3. Write a program using switch case for displaying message if percentage >75: Distinction
Percentage>60: First Class percentage>45 :Second class else Fail.
4. Write program to display the following output using while loop
10 9 8 7 6 5
5. Display the following output using for loop
see* * * * *
****
***
**
*
6. Display the following output using for loop
*
* *
***
****
*****
7. Explain goto statement with example.
8. Display following output using do-while loop
01235
9. Explain break and continue statement with the help of example.
10. Explain the conditional operator with suitable example.
11. Explain the else –if ladder with suitable example.

Unit-4 (Array ,Strings, Structure and union)

2 Marks

1. State the syntax to declare one dimensional array.


2. Define array.
3. Write syntax to initialize the one dimensional array.
4. How to declare the two dimensional array?
5. Define string.
6. Write syntax to declare and initialize strings.
7. Define structure.
8. How to declare the structure.
9. Initialize the structure “student” with variable age and name.
10. Write syntax to declare and initialize union.
11. Write features of structure.
12. Compare structure and union on the basis of memory size allocation. Commented [1]: ok
13.

4 Marks

1. Write a program to calculate the average of the array elements with size of array is 20.
2. Explain single dimensional array with example.
3. Explain two dimensional arrays with suitable example.
4. Explain string handling functions with syntax.
5. Explain arrays of structure with suitable example.
6. Write difference between structure and union.
7. Create structure “EMP” having data member name, salary. Accept data and display this
information for one employee.
8. Write a program to sort the list of 10 numbers in array in descending order.
9. Write a program to compare the two strings and display the result.

Unit-5 Functions

2 Marks

1. Define function.
2. State the types of functions.
3. State the elements of user defined function.
4. State formal and actual/informal parameter.
5. State prototyping.
6. Write the any four categories of user defined function.
7. Write the need of user defined functions.
8. State different string handling functions.
9. Write any four math functions.
10. Write syntax to declare a function.
11. State the difference between declaration and definition of function.
12. Write the syntax to define the function.
13. Define recursion.
14. Write syntax for nesting a function.
15. State the advantages of using functions.
16. Write difference between recursion and nesting of function.

4 Marks

1. Explain the need of user defined functions in c.


2. Explain any 4 math functions with syntax and example.
3. Explain how to define and call the function with suitable example.
4. Write program by using the function returning value with argument.
5. Differentiate between Call by Value and Call by Reference.
6. Explain the call by reference with suitable example.
7. Create a function prime which returns 1 if argument is prime number and zero otherwise.
8. Create a function that will scan a character string passed as an argument and convert all
lowercase character to uppercase.
9. Create a function by using the call by value to perform the exchange the values of
variables.

Unit- 6 Functions

1. State the difference between & and *;


2. Write the syntax to initialize pointers.
3. Define the pointer.
4. Declare the pointer “mp” of float type and initialize it .
5. Increment the above pointer and display the values of it.
6. State the any 4 file handling functions.
7. Declare and initialize the pointers with arrays.
8.

4 Mark

1. Explain how to initialize pointers with example.


2. Write a program to explain the arithmetic operations on pointers.
3. Write a program to decrement the pointer and display it.
4. Explain the dynamic memory allocation.
5.

Вам также может понравиться