Question #213946

Write a program for a publishing company that markets both printed books and audio visual

lectures stored on CDs. Write a class Publication thatstores title and price. Derive a class book which

has an additional member as no_pages and a class Lecture with member play_time.


Expert's answer

#include<iostream>
using namespace std;
class Publication {
private:
string title;
double price;
};
class Book: public Publication {
private:
int no_pages;

};
class Lecture: public Publication {
private:
float play_time;


};
LATEST TUTORIALS
APPROVED BY CLIENTS