11CS EM PublicQns 2 2 2 2
11CS EM PublicQns 2 2 2 2
March – 2020
11. (a) Discuss the various generations of computers.
OR
(b) Write the uses of operating system.
12. (a) Explain the types of errors in C++.
OR
(b) What is an entry controlled loop? Explain any one of the entry controlled loop with syntax and
suitable example.
13. (a) What are the key differences between if - else and switch statements in C++?
OR
(b) Explain scope rules of variables in C++ with example.
14. (a) (i) What is structure? What is its use?
(ii) Write the syntax and an example for creating a structure.
(iii) How to access members of a structure? Give example.
OR
(b) Write the output for the following C++ program.
Assume the values for age as 23, height as 161.5 and weight as 45.
#include <iostream>
using namespace std;
struct Student
{
int age;
float height, weight;
}obj;
int main()
{
cout<<”\nEnter the age:”;
cin>>obj.age;
cout<<"\nEnter the height:";
cin>>obj.height;
cout<<"\nEnter the weight:”;
cin>>cbj.wright;
cout<<”\nYour details:";
cout<<"\nAge:”<<obj.age;
cout<<"\tWeight:"<<obj.weight;
return 0;
}
15. (a) (i) Explain the main features of OOPS.
(ii) What are the advantages of OOPS.
OR
(b) Debug the given C++ program to get the following output:
Output
Sum Constructor:
Difference Constructor:
1. Add:
2. Difference:
Enter your choice :2
Enter the values for a and b :20 60
OR
(b) Explain the advantages of object oriented programming.
July - 2022
31. (a) Explain the various generation of computers.
OR
(b) Explain 1's compliment representation with an example.
32. (a) Explain the characteristics of a microprocessor.
OR
(b) Explain if...else statement with a suitable example.
33. (a) Explain the different types of inheritance.
OR
(b) Explain case analysis with an example.
34. Explain the use of header file with examples.
OR
(b) What is an entry control loop? Explain any one of the entry controlled loop with suitable
example.
..31.. A. Prabhakar - 9442979144
11 – Computer Science
35. (a) Explain call by value method with suitable example.
OR
(b) What are the rules for operator overloading?
March - 2023
36. (a) Discuss the various Generations of Computers.
OR
(b) Explain the process management algorithms in Operating System.
37. (a) (i) Write the procedure to convert fractional decimal to binary.
(ii) Convert (98.46)10 to Binary.
OR
(b) Arrange the memory devices in ascending order based on the access time.
38. (a) Explain about Binary Operators used in C++.
OR
(b) Explain Call by value method with example.
39. (a) Mention the difference between constructor and destructor
OR
(b) Write the output of the following program:
#include<iostream>
using namespace std;
int main()
{
char dev[5] [10] = {"Monitor", "Speaker", "Printer", "Scanner", "Keyboard"};
for(int i = 0 ; i<5 ; i++)
cout<< dev[i] <<”\n” ;
}
40. (a) Explain the different types of Cyber attacks.
OR
(b) Debug the following C++ program.
Output:
Constructor of base class...
Constructor of derived...
Constructor of derived1...
Destructor of derived1...
Destructor of derived...
Destructor of base class...
Program:
$include<iostream>
using namespace std;
class base()
{
Public
base()
{
cout<<"\n Constructor of base class...";
}
!base()
{
cout<<"\n Destructor of base class...";
};
}
!derived()
{
cout<<"\n Destructor of derived...";
}
};
Class derived1: public derived
{
public:
derived 1();
{
cout<<"\n Constructor of derived1...";
}
derived 1();
{
cout <<"\n Destructor of derived 1...";
}
}
int main():
{
derived1 x;
return 0;
}
June - 2023
41. (a) Explain the basic components of a computer with a neat diagram.
OR
(b) List out the uses of operating system.
42. (a) Explain the characteristics of a Microprocessor.
OR
(b) (i) Add : 11010102 +1011012
(ii) Subtract : 11010112 -1110102
43. (a) Explain control statements with suitable example.
OR
(b) Explain the main features of Object Oriented Programming.
44. (a) Explain the different visibility mode through pictorial representation.
OR
(b) (i) What are the rules for function overloading?
(ii) State the rules for Operator overloading.