MC0066
MC0066
com/collections/3154490/MCA-SEM-2 July 2011 Master of Computer Application (MCA) Semester 2 MC0066 OOPS using C++ 4 Credits
(Book ID: B0681 & B0715)
1. Write a program in C++ for matrix multiplication. The program should accept the
dimensions of both the matrices to be multiplied and check for compatibility with appropriate messages and give the output.
2. Write a program to check whether a string is a palindrome or not. Please note that palindrome is one which remains the same if you reverse the characters in the string. For example MADAM.
3. What is structure in C++? Define a structure named product with elements productcode, description, unitprice and qtyinhand. Write a C++ program that implements the structure and enables to store atleast 100 product data.
Book ID: B0715 4. What is the purpose of exception handling? How do you infer from the phrase, Throwing an exception?. . .
July 2011 Master of Computer Application (MCA) Semester 2 MC0066 OOPS using C++ 4 Credits
(Book ID: B0681 & B0715)
Book ID: B0681 1. Write a program which accepts a number from the user and generates prime numbers till that number 2. Implement a class stack which simulates the operations of the stack allowing LIFO operations. Also implement push and pop operations for the stack.
Book ID: B0715 3. What are allocators? Describe the sequence container adapters. 4. Write about the following with the help of suitable programming examples: A) Throwing an Exception B) Catching an Exception