This document contains questions for an exam on object-oriented programming with C++. It includes questions about key OOP concepts like classes, inheritance, polymorphism, operator overloading, and more. Students must answer 5 of the 20 questions in detail. The questions cover topics such as function overloading, templates, constructors, static members, friend functions, operator overloading, inheritance, abstract classes, virtual functions, and I/O streams.
This document contains questions for an exam on object-oriented programming with C++. It includes questions about key OOP concepts like classes, inheritance, polymorphism, operator overloading, and more. Students must answer 5 of the 20 questions in detail. The questions cover topics such as function overloading, templates, constructors, static members, friend functions, operator overloading, inheritance, abstract classes, virtual functions, and I/O streams.
OOP with C++ CS36 Time: 3 hrs. Max. Marks:lOO Note: Answer any FIVE full questions. a. What is object oriented programming? Rring out the salient oriented programming and object- oriented programming. h. Explain d1e different characteristics of oop. c. Explain 'volatile' qualifier and 'const' qualifier with example. features of procedure - (OR Mark.<) (08 Marks) (04 Ma rks) 2 a. Discuss the following with an example. 3 4 5 6 7 8 b c. a b. c. a b. c. a. b. c. a. b. a. b. i) Function prototyping ii) Call by reference iii) Default arguments iv) Retllrn by reference. With is an inlinc !unction'! Explain its general syntax, and demerits. Explain new and delete operators with examples. (12 Marls) (04 Marks) (04 Marts) What is function overloading? Explain with an example. (06 Marls) What arc function templates and function instant cation? Explain. (06 Marls) Write a program to create a template funct-ion for bubble sort and demonstrate the soni:lg of integers and characters. (08 Marks) What is class? Explain the strucmrc of a class with the help of an example. DitTcrcntiatc between a class and a structure. (08 Marks) What are constructors? Explain the different types of constructors \\ith suitable examples. (08 Marks) What is a static member? Explain its general synt:uc. rules and example. (06 Marks) What arc lricnd functions? Why it is rcqutred'> Explain with the help of a suitable example. (06 Mark.<) What is opl!rator overloading? Explain its general syntax and rules along with an example. (06 Marks) Write a C+1 program to perform arithmetic operation like addition and subtraction of two complex numbers. Overload the operators+ and - . (08 Marks) What is inheritance? Explain di ffcrcnt types c.f inheritance with syntax. Discuss the importance of abstract classes with example. suitable diagram a'ld ( t2 Marks) (08 Marks) What are virtual fllnctions? With an example demonstrate the usage virtual functions. ( tO Marks) What arc the vark1us II 0 streams Give the stream class hierarchy. ( tO Marks} Write short notes on : a. this' pointer b. Handling of strings inC I I c. Nested classes d. Static fur.clion. (20 Marks) For More Question Papers Visit - http://pediawikiblog.blogspot.com For More Question Papers Visit - http://pediawikiblog.blogspot.com