Create class which will have three private integer variables, where third variable should be an average of the previous two. Create set_values and get_values methods, where set_values method should be used for setting the values of two private integer variables and get_values should return the third private variable, i.e. average of first two. Use concepts of new and delete and create array of objects of the class, size of an array should be dynamic, i.e. it should be possible to enter the size of the array from keyboard. Variables of objects should be also defined interactively, i.e. from the keyboard. Don’t forget to empty memory.
can anyone do this
Last edited on
it was a simple question.
The answer is NO, anyone cannot do this. SOMEONE could do it, but not just anyone; for example a 1 year old child probably could not, and I feel confident in saying NO because even if some small child could do it, all of them certainly cannot.

I think he asked the wrong question though.
Candidate questions might have included 'can someone do this' or 'will someone do this for me'. Which have answers of yes and no, respectively.

Kidding (and English lessons) aside:
Give it a try, post your code, ask a question, and you will get excellent help here.
Last edited on
This is a story about four people named Everybody, Somebody, Anybody and Nobody. There was an important job to be done and Everybody was sure that Somebody would do it. Anybody could have done it, but Nobody did it. Somebody got angry about that, because it was Everybody’s job. Everybody thought Anybody could do it, but Nobody realized that Everybody wouldn’t do it. It ended up that Everybody blamed Somebody when Nobody did what Anybody could have.
Registered users can post here. Sign in or register to post.