This download link is referred from the post: VTU B.Tech 1st Year Last 10 Years 2011-2021 Question Papers
Firstranker's choice
17PCD13/23
--- Content provided by FirstRanker.com ---
First/Second Semester B.E. Degree Examination, June/July 2019
Programming in C and Data Structures
Time: 3 hrs.
Max. Marks: 100
Note: Answer any FIVE full questions, choosing ONE full question from each module.
--- Content provided by FirstRanker.com ---
Module-1
- a. Design a general structure of C program and explain with an example. (06 Marks)
- b. What are Identifiers? Define rules to declare an identifier. Identify the following words are valid / Invalid Identifier : i) asdl23 ii) auto iii) 2K18 iv) india. (06 Marks)
- c. Design a flow chart and develop a C - program to find area of a circle for the given radius. (08 Marks)
OR
--- Content provided by FirstRanker.com ---
- a. Explain the formatted input and output statements in C with suitable examples. (06 Marks)
- b. With example, explain Implicit and Explicit type conversion and convert the following Mathematical Expression to C - equivalent Expression. i) area = √s(s - a)(s - b)(s - c) ii) a+b (08 Marks)
- c. Write a C program to find largest of three numbers using ternary operator. (06 Marks)
Module-2
- a. Explain the following selection statements with syntax and flow chart : i) nested if ii) else - if ladder. (06 Marks)
- b. With example bring out the differences between while loop and do - while loop. (06 Marks)
- c. Design a C program to perform operations of a simple calculator using switch statement. Provide a provision to display an error message when an attempt is made to divide a number by zero. (08 Marks)
--- Content provided by FirstRanker.com ---
OR
- a. Explain the working of for loop and write a C - program to find n - Fibonacci series, where n is specified by the user. (08 Marks)
- b. Explain the following unconditional statements with syntax and example : i) goto ii) continue. (06 Marks)
- c. Design a C - program to read a Four - digit number from user and calculate the reverse of the number and check if the number is palindrome or not. (06 Marks)
--- Content provided by FirstRanker.com ---
Module-3
- a. Define Array. Explain the methods of initializing one dimensional array with suitable examples. (06 Marks)
- b. What are Functions? Explain the following terms with example. i) Function declaration ii) Function definition iii) Function call. (08 Marks)
- c. What is Recursion? Write a C program to find factorial of the given number using recursion. (06 Marks)
--- Content provided by FirstRanker.com ---
- a. Explain the String Manipulation Functions with syntax and code fragments. i) strlen ii) strcmp. (06 Marks)
- b. With example explain different type of Functions based on parameters. (08 Marks)
- c. Write a C Function to search an element in the given array using Linear search by passing array as an argument. (06 Marks)
Module-4
- a. What is Structure? Explain the methods of declaration and initialization of structures with example. (06 Marks)
- b. Write a C program to maintain record of n employee details using array of structures with three fields (id, name, salary) and print details of employee whose salary is greater than 5000. (08 Marks)
- c. What is a file? Explain fopen and fclose functions. (06 Marks)
--- Content provided by FirstRanker.com ---
OR
- a. Explain the following file operations with example : i) fprintf() ii) fseek() iii) fputc(). (06 Marks)
- b. Explain Structure within a structure with example. (08 Marks)
- c. Given a file "n.txt" which contains names. Write a C program to create a new file "abc.txt" and copy the contents from "n.txt" to "abc.txt". (06 Marks)
--- Content provided by FirstRanker.com ---
Module-5
- a. Explain different dynamic memory allocation schemes in C with example. (08 Marks)
- b. Explain any three preprocessor directives with example. (06 Marks)
- c. Develop a C program to swap two numbers using pointers. (06 Marks)
--- Content provided by FirstRanker.com ---
OR
- a. What is a Stack? Explain the operations on stack. (06 Marks)
- b. Explain the concept of adding and deleting nodes in the linked list. (07 Marks)
- c. What are Pointers? How pointer variables are declared and initialized. (07 Marks)
--- Content provided by FirstRanker.com ---
This download link is referred from the post: VTU B.Tech 1st Year Last 10 Years 2011-2021 Question Papers
--- Content provided by FirstRanker.com ---