Question
What is the primary purpose of using private class
members in object-oriented programming?Solution
In object-oriented programming (OOP), private class members (such as variables or methods) are used to enforce encapsulation and data hiding. Here’s a detailed explanation of their purpose and benefits: • Encapsulation: Private class members are intended to be accessible only within the class that defines them. This encapsulation helps in hiding the internal state and implementation details of the class from the outside world, allowing the class to maintain control over its own data and behavior. • Data Hiding: By making members private, a class can prevent external code from directly accessing or modifying its internal data. This ensures that the internal state of an object is protected from unintended or unauthorized changes, which can help maintain the integrity and consistency of the object's state.
For a large infrastructure project, which of the following is typically the MOST expensive source of finance?
The main objective of cost accounting is _______.
A pharma company spends ₹50 crore on early-stage drug molecule research (feasibility not established). Later spends ₹30 crore proving commercial via...
Which country has officially joined the New Development Bank (NDB) in May 2025?
The rate of TDS for Rent of Land and Building, Land appurtenant to a building is:
A company has debt of ₹50 lakh at 10% interest, equity of ₹1 crore with cost of equity 15%, and tax rate 30%. Calculate the WACC (weighted by market...
The return forgone for the undertaking an investment is known as?
Who is the designated authority to receive information under the reporting requirements of the PML (Maintenance of Records) Rules, 2005?
The government’s GST Sahay app is designed to help MSMEs with:
What is the journal entry for charging Depreciation under Cost Method?
