www.andhracolleges.com
Electronics & Computer Engineering, Aeronautical Engineering and
Instrumentation & Control Engineering)
Time: 3 hours Max Marks: 80
Answer any FIVE Questions
All Questions carry equal marks
⋆⋆⋆⋆⋆
2. (a) Distinguish between getchar and scanf functions for reading strings.
(b) Write a program to count the number of words, lines and characters in a text.
[8+8]
www.andhracolleges.com
(b) State whether each of the following statements is true or false. Give reasons.
i. An integer can be added to a pointer.
ii. A pointer can never be subtracted from another pointer.
iii. When an array is passed as an argument to a function, a pointer is passed.
iv. Pointers can not be used as formal parameters in headers to function
definitions.
(c) If m and n have been declared as integers and p1 and p2 as pointers to integers,
then find out the errors, if any, in the following statements.
i. p1 = &m;
ii. p2 = n;
iii. m=p2-p1;
iv. *p1 = &n; [4+6+6]
4. (a) Differentiate between a structure and union with respective allocation of mem-
ory by the compiler. Given an example of each.
www.andhracolleges.com
5. Write a C program to read information about the student record containing stu-
dent’s name, student’s age and student’s total marks. Write the marks of each
student in an output file. [16]
(a) Recursion
(b) Applications of Stacks and Queues [8+8]
7. (a) Write a C program to copy one binary tree to another binary tree.
(b) Write in detail about AVL trees. [8+8]
8. What is a heap? Show how would you perform a heap sort using a heap. Derive
the time complexity of the heap sort in the best and worst cases. [4+6+6]
⋆⋆⋆⋆⋆
www.andhracolleges.com
Seminar Topics - Scholarships - Admission/Entrance Exam Notifications
2 ofUSA-UK-Australia-Germany-France-NewZealand
2 Universities List
www.andhracolleges.com
Electronics & Computer Engineering, Aeronautical Engineering and
Instrumentation & Control Engineering)
Time: 3 hours Max Marks: 80
Answer any FIVE Questions
All Questions carry equal marks
⋆⋆⋆⋆⋆
1. (a) What is the difference between signed integer and unsigned integer in terms
of memory and range.
(b) List the entire data types in C. What is the size of each of these data types.
[8+8]
2. (a) Distinguish between formal variable and actual variable.
(b) Distinguish between local and global variable.
(c) Distinguish between call by value and call by reference. [4+4+8]
3. (a) Write a C program using pointer for string comparison.
(b) Write a C program to arrange the given numbers in ascending order using
pointers. [8+8]
www.andhracolleges.com
4. (a) What are Bit fields. What are its advantages. What is its syntax.
(b) Write a C program to store the information of vehicles. Use bit fields to store
the status information. Assume the vehicle object consists of type, fuel and
model member fields. Assume appropriate number of bits for each field.[8+8]
5. (a) How does an append mode differs from a write mode.
(b) Compare between printf and fprint f functions.
(c) Write a program to copy upto 100 characters from a file to an output array.
[4+4+8]
6. Write a C program using pointers to implement Queue with all operation. [16]
7. (a) What is preorder traversal method?
(b) Explain a procedure for preorder traversal of a binary tree with an example
in detail. Analyze the time complexity of your procedure. [8+8]
8. Write a C program that searches a value in a stored array using binary search.
What is the time complexity of binary search? [16]
⋆⋆⋆⋆⋆
Seminar Topics - Scholarships - Admission/Entrance Exam Notifications
1 ofUSA-UK-Australia-Germany-France-NewZealand
1 Universities List
www.andhracolleges.com
Electronics & Computer Engineering, Aeronautical Engineering and
Instrumentation & Control Engineering)
Time: 3 hours Max Marks: 80
Answer any FIVE Questions
All Questions carry equal marks
⋆⋆⋆⋆⋆
1. Write about space requirements for variables of different data types. [16]
4. (a) Explain with an example how a structure can be organized in the ‘C’ language?
(b) Write a C program to print maximum marks in each subject along with the
www.andhracolleges.com
name of the student by using structures. Take 3 subjects and 3 students
records. [8+8]
7. Define linked list. Explain various operations performed on linked lists with suitable
algorithms. [16]
8. Write a C program to sort a given list of elements using tree sort and discuss its
time complexity. [16]
⋆⋆⋆⋆⋆
www.andhracolleges.com
Electronics & Computer Engineering, Aeronautical Engineering and
Instrumentation & Control Engineering)
Time: 3 hours Max Marks: 80
Answer any FIVE Questions
All Questions carry equal marks
⋆⋆⋆⋆⋆
1. Write about space requirements for variables of different data types. [16]
3. (a) Explain the process of declaring and initializing pointers. Give an example.
(b) Write a C program that uses a pointer as a function argument. [8+8]
www.andhracolleges.com
following fields; Access number, author’s name. Title of the book, year of
publication, publisher’s name, price. [6+10]
5. Write a C program to replace every 5th character of the data file, using fseek( )
command. [16]
6. What is a data structure? Explain the various types of data structures with suitable
example. [4+12]
7. (a) Construct a binary tree for the following preorder and inorder traversals.
i. Pre order : ABCDEFGHIJKLMNOPQ
ii. In order : DECFBHGAKMLJIORNQP
(b) Prove that a binary tree with n leaves contains 2n-1 nodes. [8+8]
⋆⋆⋆⋆⋆