Question: JAVA CODE ONLY please Q.1. An advertising campaign consists of a set of advertisements. Adverts can be of several types, for example: a roadside Hoarding,
JAVA CODE ONLY please


Q.1. An advertising campaign consists of a set of advertisements. Adverts can be of several types, for example: a roadside Hoarding, a Newspaper ad, TV commercial, or Poster. Each type of advert has a cost associated with it: a fixed fee to cover materials, production staff and media costs, and variable costs for buying advertising time and space. An advertising campaign consists of one or more advert-events: A Hoarding for a poster is hired for a number of days. The standard cost is H per hoarding. An additional surcharge of 50% is charged for prime locations. Newspaper: The cost is N per column cm. TV commercial: Air time is sold by the seconds. The standard cost is T per second, which doubles at peak times. Class name Advert Hoarding Cost method Fees Fees + Rate number of days Variables associated Fees Rate, number of days. location NewsPaperAd If prime location, 50% of total bill is additionally charged Feest Rate * columncm Rate, columncm Feest Rate *timeinsec Rate, timeinsec If prime time, double charges apply. TVAd Create a class Campaign which can store an array for the different types of advertisements used and calculates the total cost of all advertisements for that campaign. Note: You can include variables and methods as required
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
