Get premium membership and access questions with answers, video lessons as well as revision papers.

Given the following class, show how an object called ob that passes the value 100 to a and X to c would be declared class sample...

      

Given the following class, show how an object called ob that passes the value 100 to a and X to c would be declared
class sample {
int a;
char c;
public:
sample(int x, char ch) {a = x; c = ch;}
//...
};

  

Answers


Davis

sample on(100, 'X');
Githiari answered the question on May 12, 2018 at 17:41


Next: State five functions of advertising agencies.
Previous: What is wrong with the following fragment? //This program has an error. #include using namespace std; class c11 { int i, j; public: c11 (it a, int b) { i =...

View More Computer Science Questions and Answers | Return to Questions Index


Learn High School English on YouTube

Related Questions