About Me

My photo
Vijayapur, Karnataka, India
I am interested in Teaching.

Sunday 18 June 2017

PCD Module Wise Important Questions for Annual Examination

Module-I
1. What is pseudocode? Write pseudocode to find simple interest.

2. Discuss "Structure of C Program" with programming example.

3. What are C-tokens? List and explain in brief.

4. What is variable? Write rules for defining variables with valid and invalid example for each rule.
or
 What are identifiers? Write rules for defining identifiers with valid and invalid example for each rule.

5. What are datatypes? List and explain in brief with range of values supported by them.
6. Explain the following C-operators with examples.

    Relational, Logical, Bitwise, Special operators(sizeof(), comma) and conditional operator(?:).

7. What is meant by precedence and asociativity of operators? Explain with example.

8. Solve the following C- Expression.
    10<9+5&&500*10, 4||5&&3&&!7

9. What is type conversion(typecast)? List and explain types of type conversions with example.

10. Convert the following Mathematical expressions into C-expressions.
   


11. Write C programs for following.

To find simple interest.
To find area and perimeter of triangle  by reading breadth and height of it.
To find area and perimeter of triangle  by reading 3 sides of it.
To find area and perimeter of rectangle.
To convert the temperature reading from Fahrenheit to Celsius.
To swap two values using temporary variable.
To swap two values without using temporary variable.

Module-2
1. What are decision making (branching or conditional) statements ? Discuss any three with SYNTAX, FLOWCHART and PROGRAMMING example.
or
 Discuss the following with syntax,flow chart and programming example.
                    a) simple...if  b)if..else  c)nested if  d) else..if ladder (cascaded if )

2. Discuss "switch" statement with SYNTAX, FLOWCHART and programming example.

3. What are loop (repetitive or loop) statements ? Discuss any three with SYNTAX, FLOWCHART and PROGRAMMING example.
or
 Discuss the following with syntax,flow chart and programming example.
                    a) the while loop    b) the do...while loop    c) the for loop.

4. Write minimum 5 differences between while(pretest or entry controlled)  and do...while (post test or exit controlled) loop.

5. Write minimum 5 differences between break and continue statements.

6. What is goto (unconditional) statement? discuss with example.

7. Write the C programs for following.

To check, whether the year is leap or not leap year.
To find largest of two numbers.
To find largest of three numbers.
To reverse a number.
To check, whether the number is PALINDROME or NOT PALINDROME
To find factorial of n
To find gcd and lcm of two numbers.

Module-3

1. What is one dimensional array? Explain its declaration and initialization with syntax and example.

2. What is two dimensional array? Explain its declaration and initialization with syntax and example.

3. What is string? Explain its declaration and initialization with syntax and example.

4. Discuss the following string manipulating functions with examples.
    strlen, strcpy, strncpy, strcmp, strncmp, strcat. strncat, strlwr, strupr, strrev

5. Write the C programs for following.

To find addition of two one dimensional arrays.
To implement Bubble Sort technique.
To implement Linear Search technique.
To implement Binary Search technique.
To find addition of two 2D arrays
To find multiplication of two 2D arrays
To find length of a string without using built in function.

Functions:
1. Discuss the "Elements of User Defined Functions" with syntax and examples.

2. What are actual and formal parameters? Give programming example.

3. What is recursive function? Write recursive function to find factorial of 'n'.

4. Discuss 'parameter passing mechanisms' with programming example to each. (call by value and call by reference)
or
Write differences between 'call by value' and call by reference' (call by address)

5. Write C program to swap two values using defined function to swap two values.(call by reference) vimp.

6. Discuss the following with example.
automatic variables, global variable, static variables and register variables.

7.  Write C program that calls isprime(n) as a user defined function that returns 1 if the number is prime;otherwise, 0.

Module-4

Structure:

1. What is structure?Explain its declaration and initialization with syntax and examples.

2. Write differences between arrays and structures.

3. What is nested structure? Give programming example.

4. Discuss 'arrays of structure' with programming example.

5. Discuss 'structure and functions' with example.

6. What is typedef statement? Give examples.

7. Write C program to read and display 'n' students information (Roll No, Name, Marks, Grade) using arrays of structure.

File Management:

1. What is file? Discuss defining, opening and closing a file with syntax and example.

2. Discuss the following "File Manipulation Functions" with syntax and examples.
    getc() and putc()
    getw() and putw()
    fscanf() and fprintf()
    gets() and puts()

Module-5

1. What is pointer? Discuss its declaration and initialization with syntax and examples.

2. What is dynamic memory allocation? Explain the following functions with example.
     malloc(), calloc(), realloc(), free()

3. List and explain non-primitive data structures. (stack,queue,linked list, tree and graph)

4. What are preprocessors? list and explain 3 types.
   a) Macro substitution b) File inclusion c) Compiler control

5. Discuss 'stack' with explanation, figure and applications.

6. Discuss 'queue' with explanation, figure and applications.

7. Discuss 'linked list' with explanation and  figure.






Dear student,
Remember one thing i.e. if you write more then you get good and more marks.So, you need to explain the topics with quality points and SYNTAX  and PROGRAMMING EXAMPLE compulsory.

Tips:
1. Preferably, attempt that question first in which you are perfect.
2. For every question minimum one page answer.
3. For 10 Marks, minimum 3 pages. (front,back,front)
4. Wherever necessary, give the programming examples as you memorized for lab.
5. Write MORE to get MORE marks.
6. Your answers must be neat and tidy.
7. Do not forget to underline or bold the important words in your answer.
8. Draw rectangle box around SYNTAX compulsory.
9. Send you feedback or suggestion to cs.kusur@gmail.com
10. All the best...










GCD of two numbers and its application...

The greatest common divisor (gcd) of two numbers is the largest positive integer that divides both numbers without leaving a remainder. The ...