Geschreven door studenten die geslaagd zijn Direct beschikbaar na je betaling Online lezen of als PDF Verkeerd document? Gratis ruilen 4,6 TrustPilot
logo-home
Tentamen (uitwerkingen)

PYQ'S from

Beoordeling
-
Verkocht
-
Pagina's
67
Cijfer
A+
Geüpload op
30-12-2025
Geschreven in
2025/2026

In this you will find PREVIOUS YEAR QUESTIONS along with their Answers of the following subject and ace your exam with common questions, usable for all BOARDS

Instelling
Vak

Voorbeeld van de inhoud

UNIT-1: OBJECT ORIENTED
PROGRAMMING IN C++
Very Short Answers (VSA).
1. What is an identifier?
It is the name given to a fundamental building block in a
program, such as a variable, function, class, or array.
2. What do you understand by the base type of an array?
The "base type" is the data type of the elements stored in the
array (e.g., in int A[10];, int is the base type).
3. What is meant by a floating constant in C++?
It is a numerical literal that contains a decimal point or an
exponent (e.g., 3.14, 0.5e-2).
4. What is the effect of absence of 'break' in switch-case
statement?
"Fall-through" occurs: the program continues to execute all
subsequent cases until it finds a break or the switch ends.
5. What is the difference between 'a' and "a" in C++?
* 'a' is a character constant (1 byte).
* "a" is a string literal (2 bytes: 'a' + null terminator \0).
6. What is data type?
It specifies the type of data a variable can hold (e.g., int, float)
and the operations that can be performed on it.
7. What do you mean by operator?
A symbol that tells the compiler to perform specific
mathematical or logical manipulations (e.g., +, *, &&).
8. What does the modulus operator '%' do?
It returns the remainder of an integer division.
9. ? : operator can be used in place of if-else statement.
(This is the Conditional or Ternary Operator).

,10. What is a nested if statement?
An if statement placed inside another if or else block.
11. If x=20 and y=10, then what does x > y && (x * y) > y evaluate
to?
Answer: (iii) True (or 1).
Reason: 20 > 10 is True. 200 > 10 is True. True && True = True.
12. What is the difference between == and = in C++?
* = is the Assignment operator (sets value).
* == is the Relational operator (compares values).
13. How does a class enforce data-hiding in C++?
By using Access Specifiers (specifically private and protected),
which restrict direct access to data from outside the class.
14. Write one property of static data member.
A static data member is shared by all objects of the class; only
one copy exists in memory.
15. What is visibility mode?
It determines how base class members are inherited by the
derived class (Public, Private, or Protected inheritance).
16. Explain scope resolution operator (::) in C++.
It is used to access global variables, static members, or define
member functions outside the class body.
17. What type of C++ class members are not inherited?
Constructors, Destructors, and the Assignment Operator (=) are
not inherited.
18. What is a nested class?
A class declared inside another class.
19. What is a destructor?
A special member function with the same name as the class
preceded by ~, used to deallocate memory when an object is
destroyed.
20. Which of these is called first when an object of a derived
class is created?

,(i) Constructor of the base class. (Base constructs first, then
Derived).
21. What is a concrete class?
A class for which objects can be created (it has no pure virtual
functions).
22. What is to be done to make a data member static?
Declare it with the keyword static inside the class, and define it
outside the class using the scope resolution operator.
23. Header file required for tolower()?
<ctype.h> (or <cctype> in modern C++).
24. What is meant by base address of an array?
The memory address of the first element (index 0) of the array.
25. What is meant by instantiation?
The process of creating an object (instance) of a class.
26. What do you understand by constructor overloading?
Defining multiple constructors in the same class with different
parameter lists (different number or types of arguments).
27. What is the significance of tellg() function?
It returns the current position of the get (input) pointer in a file.
28. What is meant by dynamic memory allocation?
Allocating memory at runtime using the new operator (instead of
compile time).
29. What values will array elements have if declared without an
initializer?
They will contain Garbage Values (random data).
30. What is a derived class?
A class that inherits properties and behaviors from another class
(the Base class).
31. Define inheritance.
The capability of one class to acquire the properties and
characteristics of another class.
32. What is a Constructor?

, A special member function that initializes an object upon
creation. It has the same name as the class.
33. What is the purpose of 'new' operator in C++?
It is used to allocate memory dynamically (at runtime) on the
heap.
34. Suppose an array 'arr' contains three elements. How would
you declare and initialize a pointer to this array?
int *ptr = arr; (The name of the array acts as the pointer to the
first element).
35. State two advantages of C++.
* Object-Oriented support (reusability).
* Closer to hardware (efficient memory management).
36. What is a class?
A blueprint or template that defines the variables and functions
common to all objects of a certain kind.
37. What is an object?
An instance of a class. It is the actual runtime entity created
from the class blueprint.
38. State two data types of C++.
* Built-in: int, float, char.
* User-defined: class, structure.
39. What is member function?
A function declared inside a class that can access the class's
private data.
40. What is a binary file?
A file that stores data in the same format as it is held in memory
(0s and 1s), not as human-readable text.
41. Define constructor.
A special member function with the same name as the class,
used to initialize objects automatically when they are created.
42. State one feature of C++.

Geschreven voor

Instelling
Middelbare school
Vak
School jaar
5

Documentinformatie

Geüpload op
30 december 2025
Aantal pagina's
67
Geschreven in
2025/2026
Type
Tentamen (uitwerkingen)
Bevat
Vragen en antwoorden

Onderwerpen

$3.99
Krijg toegang tot het volledige document:

Verkeerd document? Gratis ruilen Binnen 14 dagen na aankoop en voor het downloaden kun je een ander document kiezen. Je kunt het bedrag gewoon opnieuw besteden.
Geschreven door studenten die geslaagd zijn
Direct beschikbaar na je betaling
Online lezen of als PDF

Maak kennis met de verkoper
Seller avatar
lrd93

Maak kennis met de verkoper

Seller avatar
lrd93 Ramanujan Sr. Sec. Schl
Volgen Je moet ingelogd zijn om studenten of vakken te kunnen volgen
Verkocht
-
Lid sinds
4 maanden
Aantal volgers
0
Documenten
1
Laatst verkocht
-

0.0

0 beoordelingen

5
0
4
0
3
0
2
0
1
0

Recent door jou bekeken

Waarom studenten kiezen voor Stuvia

Gemaakt door medestudenten, geverifieerd door reviews

Kwaliteit die je kunt vertrouwen: geschreven door studenten die slaagden en beoordeeld door anderen die dit document gebruikten.

Niet tevreden? Kies een ander document

Geen zorgen! Je kunt voor hetzelfde geld direct een ander document kiezen dat beter past bij wat je zoekt.

Betaal zoals je wilt, start meteen met leren

Geen abonnement, geen verplichtingen. Betaal zoals je gewend bent via iDeal of creditcard en download je PDF-document meteen.

Student with book image

“Gekocht, gedownload en geslaagd. Zo makkelijk kan het dus zijn.”

Alisha Student

Bezig met je bronvermelding?

Maak nauwkeurige citaten in APA, MLA en Harvard met onze gratis bronnengenerator.

Bezig met je bronvermelding?

Veelgestelde vragen