V.S.B ENGINEERING COLLEGE DEPARTMENT OF INFORMATION TECHNOLOGY I IT-II Semester Sl.No Subject Name Page No. 1 Programming & Data Structures-I 2
CS6202 - PROGRAMMING & DATA STRUCTURES UNIT I Part - A 1. What are Keywords? 2. What is the difference between if and while statement? 3. What is the difference between while loop and do while loop? 4. What will happen when you access the array more than its dimension? 5. Write the limitations of getchar( ) and sacnf( ) functions for reading strings getchar() 6. What is the output of the programs given below? 7. Distinguish between Call by value Call by reference. 8. What is the difference between while(a) and while(!a)? 9. Why we don t use the symbol & symbol, while reading a String through scanf()? 10. What is the difference between static and auto storage classes? 11. Define delimiters in C. 12. Differentiate break and continue statement. 13. Compare switch( ) and nestedif statement. 14. Give the syntax for the for loop statement 15. What is the use of sizeof( ) operator? 16. What is a loop control statement? 17. What are global variable in C? 18. Write a program to swap the values of two variables (without temporary variable). 19. What is an array? 20. What is a Pointer? How a variable is declared to the pointer? 21. What are the uses of Pointers? 22. What is the output of the program? 23. How can you return more than one value from a function? 24. What are the main elements of an array declaration? 25. List the header files in C language. UNIT II Part A 1. Define structure. 2. What is meant by structure template? 3. Write the syntax for structure declaration and definition 4. Define union. 5. Write the syntax for union declaration and definition. 6. How structures are initialized? Give example. 7. What are nested structures? 8. What is meant by array of structures? 9. What is structure assignment? 10. How do you reference a structure member? 11. Differentiate structure and union. 12. 13.What are the advantages of union over structure? 13. Write the syntax for pointers to structure. 14. What is a file? 15. Write the syntax for file declaration. 16. What are file modes? 17. Write the syntax to open a file. 18. What is the significance of fclose() function? 19. What are the steps for using a file? 20. What are the functions of text files in stdio library? 21. What are the file pointers of stdlib.h? 22. What are the types of files? 24. What are the features of binary files?
23. What are the functions to access files randomly? Unit III Part A 1. What is a data structure? 2. Why do we need data structures? 3. List some common data structures. 4. How data structures are classified? 5. Differentiate linear and non-linear data structure. 6. Define ADT(Abstract Data Type) 7. Mention the features of ADT. 8. Define List ADT 9. What are the ways of implementing linked list? 10. What are the types of linked lists? 11. How the singly linked lists can be represented? 12. How the doubly linked list can be represented? 13. What are benefits of ADT? 14. When singly linked list can be represented as circular linked list? 15. When doubly linked list can be represented as circular linked list? 16. Where cursor implementation can be used? 17. List down the applications of List. 18. What are the advantages of linked list? 19. Mention the demerits of linked list 20.How the polynomial is represented using linked lists? 21. What are the operations performed in list? 22. What are the merits and demerits of array implementation of lists? 22. What is a circular linked list? Unit IV Part - A 1. Define Stack. 2. What are the operations of the stack? 3. Write the routine to push a element into a stack. 4. How the operations performed on linked list implementation of stack? 5. What are the applications of stack? 6. What are the methods to implement stack in C? 7. How the stack is implemented by linked list? 8. Write the routine to pop a element from a stack. int 9. Define queue. 10. What are the operations of a queue? 11.Write the routine to insert a element onto a queue. 12.What are the types of queue? 13. Define double ended queue 14.What are the methods to implement queue in C? 15. How the queue is implemented by linked list? 16. Write the routine to delete a element from a queue int 17. What are the applications of queue? 18. Define circular queue 19. What are push and pop operations? 20. What are enqueue and dequeue operations? Unit V Part A 1.Define sorting 2.Mention the types of sorting 3.What do you mean by internal and external sorting? 4.Define bubble sort
5.How the insertion sort is done with the array? 6. What are the steps for selection sort? 7. What is meant by shell sort? 8. What are the steps in quick sort? 9. Define radix sort 10. What are the advantages of insertion sort 11.Define searching 12.Mention the types of searching 13. What is meant by linear search? 14.What is binary search? 15. Define hashing function 16. What is open addressing? 17.What are the collision resolution methods? 19. Define separate chaining 16 MARK QUESTIONS UNIT_I PART B 1. Explain about the various decision making statements in C language. 2. Explain the control statements in c. 3. What are functions? Explain the types of functions in detail with an example program for each type. 4. Define arrays. Explain the array types with an example program for each type 5. What are pointers? When and why they are used? Explain in detail with sample programs. 6. Describe in detail about the Preprocessors in C. 7. Explain function pointers with example. 8. Explain about function with variable number of arguments.? UNIT-II 1. Explain the different modes in which a file can be opened. 2. Explain the functions fscanf, fprintf, fgets, fputs, getw, putw, getc, putc, fread, fwrite, feof, ferror,fseek,ftell,rewind with example. 3. Explain structures with an example 4. Explain union with an example 5. Discuss about the file handling concepts in C 6. Explain different ways to read data from a file. 7. Explain different ways to write data to a file 8. Design a c program to create the employee database and to perform the manipulations such as adding a record, deleting a record, updating a record. 9. Explain about structure within structure with example. UNIT-III 1. Explain the various operations of the list ADT with examples 2. Write the program for array implementation of lists 3. Write a C program for linked list implementation of list. 4. Explain the operations of singly linked lists 5. Explain the operations of doubly linked lists 6. Explain the operations of circularly linked lists 7. How polynomial manipulations are performed with lists? Explain the operations 8. Explain the steps involved in insertion and deletion into an singly and doubly linked list. UNIT IV Part B 1. Explain Stack ADT and its operations 2. Explain array based implementation of stacks
3. Explain linked list implementation of stacks 4. Explain the applications of Stacks 5. Explain how to evaluate arithmetic expressions using stacks 6. Explain queue ADT 7. Explain array based implementation of queues 8. Explain linked list implementation of queues 9. Explain the applications of queues 10. Explain circular queue and its implementation 11. Explain double ended queue and its operations UNIT_V 1. Explain the sorting algorithms 2. Explain the searching algorithms 3. Explain hashing 4. Explain open addressing 5. Write a C program to sort the elements using bubble sort. 6. Write a C program to perform searching operations using linear and binary search. 7. Explain in detail about separate chaining.