give me some class & objects examples?



give me some class & objects examples?..

Answer / divyaja

Sometimes, a programmer will want to
define a custom "thing" and the operations
that can be performed on that "thing"
• A class is the definition
• An object is a particular instance of a class
• Classes contain
– data, called members
– functions, called methods

Is This Answer Correct ?    7 Yes 0 No

Post New Answer

More C++ General Interview Questions

A company pays its salespeople on a commission basis. The salespeople receive $200 per week plus 9 percent of their gross sales for that week. For example, a saleperson who sells $5000 worth of merchandise in a week receives $200 plus 9 percent of $5000, or a total of $650. You have been supplied with a list of items sold by each salesperson. The values of these items are as follows: Item Value A 239.99 B 129.75 C 99.95 D 350.89 Write a program that inputs one salesperson's items sold in a week (how many of item A? of item B? etc.) and calculates and displays that salesperson's earnings for that week.

0 Answers  


What is a buffer c++?

0 Answers  


What are the advantages of using pointers in a program?

0 Answers  


What is meant by reference variable in C++?

1 Answers  


Explain stack & heap objects?

0 Answers  






What is difference between malloc()/free() and new/delete?

0 Answers  


What is low level language in simple words?

0 Answers  


What are the characteristics of friend functions?

0 Answers  


What is encapsulation in c++?

0 Answers  


How do I tokenize a string in c++?

0 Answers  


Explain Text Manipulation Routines?

0 Answers  


What is the basic structure of c++ program?

0 Answers  


Categories