KEMBAR78
PST Using C - Question Bank 2024 | PDF | Pointer (Computer Programming) | Function (Mathematics)
0% found this document useful (0 votes)
35 views4 pages

PST Using C - Question Bank 2024

Uploaded by

leonardk139
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
35 views4 pages

PST Using C - Question Bank 2024

Uploaded by

leonardk139
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 4

JYOTI NIVAS COLLEGE AUTONOMOUS

BANGALORE
PROBLEM SOLVING TECHNIQUES USING C
BCA, BCA DS and BSc PMC/PJC/MEC
QUESTION BANK SEP - 2024

SECTION A 2 Marks

1. Define an algorithm.
2. What does it mean to say that algorithms are a technology?
3. List the basic steps involved in solving a problem using an algorithm.
4. Why is it important to analyze algorithms?
5. What are the key considerations when designing an algorithm?
6. Explain the significance of growth of functions in the context of algorithms.
7. Define asymptotic notation and its use in algorithm analysis.
8. What are the common asymptotic notations used in algorithm analysis?
9. Provide examples of standard notations for algorithm complexity.
10. Define space complexity
11. What is time complexity
12. Why is the C programming language considered important?
13. Define C tokens and give two examples.
14. What are identifiers in C? Provide an example.
15. What is a variable in C, and how is it declared?
16. Define a constant and explain its significance in C programming.
17. What are symbolic constants in C? Provide an example.
18. List two types of operators in C and provide an example of each.
19. Explain the term 'type conversion' in C with an example.
20. What is the syntax of the 'if' statement in C?
21. Describe the 'else-if ladder' in decision-making in C.
22. What is the difference between the 'switch' statement and the 'if-else' statement in C?
23. Explain the use of the conditional (?:) operator in decision-making.
24. What is the role of the 'goto' statement in C?
25. What is a format specifier?
26. Define a one-dimensional array.
27. How do you declare a character array in C?
28. What is recursion in programming?
29. How do you pass an array to a function in C?
30. How do you access an element of a two-dimensional array?
31. What is the difference between a string and a character array?
32. Define a user-defined function. Provide an example.
33. What are the elements of a user-defined function in C?
34. How do you initialize a string in C?
35. What is a pointer in C?
36. How do you declare a pointer to a structure?
37. What is the difference between a structure and a union?
38. Define command-line arguments in C.
39. What is a null pointer in C?
40. How do you declare a pointer to an array in C?
41. What is the difference between a structure and an array?
42. How do you define a union in C?

SECTION B 6 Marks

1. Describe the growth of functions in the context of algorithm analysis.


2. Explain the algorithm for counting the number of elements in a set.
3. Describe the algorithm for exchanging the values of two variables.
4. Explain the algorithm for counting the number of elements in a set.
5. Write an algorithm to find the summation of a set of numbers.
6. How can you generate the Fibonacci sequence using an algorithm?
7. Explain the algorithm to reverse the digits of an integer.
8. What is the basic structure of a C program?
9. What is the difference between a keyword and an identifier in C?
10. What is the precedence of arithmetic operators in C? Solve the following expression
result = 5 + 3 * 2 - 8 / 4;
11. What is the difference between the 'while' and 'do-while' loops in C?
12. What is a nested loop in C? Provide an example.
13. Differentiate between formatted and unformatted I/O functions in C.
14. Explain the purpose of the 'break', ‘goto’ and 'continue' statements in C loops.
15. Name the basic data types in C.
16. Explain Unary Operators in C with Examples.
17. Explain the significance of identifiers, keywords, and constants. Provide examples of
each and describe how they are used in C programming.
18. Explain the role of operators in C programming. What is operator precedence?
19. Illustrate with an example how expressions are evaluated based on operator
precedence and explain type conversion rules.
20. What is the difference between a symbolic constant and a regular variable in C?
21. Explain how to declare and initialize a two-dimensional array with an example.
22. Describe string-handling functions in C with examples.
23. Write a short note on user-defined functions and their categories.
24. Describe the steps involved in passing an array to a function in C. Provide an example.
25. Explain the relationship between pointers and arrays with an example.
26. Describe how pointers can be used with character strings.
27. Explain the difference between structures and unions in C.
28. How do you perform input and output operations on a file in C? Provide a simple
example.
29. Describe how pointers are used with structures in C. Provide an example.
30. Explain the concept of a pointer to a pointer with an example.
31. Write a C program to copy one string into another using pointers.
32. Discuss how unions save memory compared to structures. Provide an example.
33. Explain the difference between structures and unions in C with examples.
34. Explain how command-line arguments are used in C programming with a simple
example.

SECTION C 10 Marks

1. Discuss the role of algorithms in computing and why they are considered foundational to
computer science. Provide examples of algorithm applications in real-world computing.
2. Explain the steps involved in solving a problem using algorithms. Discuss the
significance of each step with appropriate examples.
3. What is the importance of analyzing algorithms? Explain how algorithm analysis helps in
evaluating performance. Use examples to demonstrate the relevance of time and space
complexity.
4. Explain asymptotic notation and its importance in algorithm analysis. Discuss the Big O,
Big Omega, and Big Theta notations with examples of common functions like constant,
logarithmic, linear, and polynomial functions.
5. Design algorithms for the following fundamental operations:
a. counting the number of elements in a set
b. calculating the factorial of a number.
Provide a step-by-step explanation and discuss the efficiency of each algorithm.
6. Write and explain algorithms for
a. exchanging the values of two variables
b. summing a set of numbers
7. a. Write an algorithm to convert a character to its corresponding ASCII value
b. Write an algorithm for Reversing the digits of an integer.
8. Elaborate on C tokens, data types, variables, constants, and symbolic constants.
Additionally, explain the role of operators in C, including operator precedence and type
conversions in expressions, using examples.
9. Discuss formatted and unformatted I/O functions in C. Explain the significance of printf()
and scanf(), and provide examples of how to use these functions for input and output
operations.
10. Describe the decision-making statements in C. Explain how the if, if-else, else-if ladder,
and switch statements work.
11. Explain the concept of operators in C programming. Describe the different types of
operators (arithmetic, relational, logical, etc.).
12. Explain multidimensional arrays with examples, and demonstrate how to access and
modify elements.
13. Discuss in detail string manipulation functions in C.
14. Discuss character arrays and strings in C programming. Write a C program that reads a
string from the user and counts the number of vowels, consonants, and digits in it.
15. Explain recursion with an example of a recursive function for fibonacci series.
16. Describe the concept of recursion with its advantages and disadvantages.
17. Explain pointers in C in detail. Write a program that swaps two numbers using pointers.
18. Discuss structures and unions in C. Write a program that uses both structures and
unions to store and display student information.
19. Write a C program that demonstrates how to open, read, write, and close a file.
20. Explain command-line arguments with a program.
21. Write a detailed explanation of pointer arithmetic. Provide a C program to demonstrate
the addition and subtraction of pointers.
22. Explain the concept of an array of structures with an example. Write a C program that
stores and displays student information using an array of structures.
23. Write a C program to demonstrate reading from and writing to a file. Explain the steps
involved in file handling.
24. Discuss the use of structures in C programming with examples. Write a program that
uses structures to store and display employee information.

You might also like