Page 1 of 1

Lab 8.24 ***C++*** "Artwork label (classes/constructors)"

Posted: Thu Jul 14, 2022 2:07 pm
by answerhappygod
Lab 8.24 ***C++*** "Artwork label (classes/constructors)"
Lab 8 24 C Artwork Label Classes Constructors 1
Lab 8 24 C Artwork Label Classes Constructors 1 (75.02 KiB) Viewed 44 times
Lab 8 24 C Artwork Label Classes Constructors 2
Lab 8 24 C Artwork Label Classes Constructors 2 (17.7 KiB) Viewed 44 times
Lab 8 24 C Artwork Label Classes Constructors 3
Lab 8 24 C Artwork Label Classes Constructors 3 (40.74 KiB) Viewed 44 times
Lab 8 24 C Artwork Label Classes Constructors 4
Lab 8 24 C Artwork Label Classes Constructors 4 (37.72 KiB) Viewed 44 times
Lab 8 24 C Artwork Label Classes Constructors 5
Lab 8 24 C Artwork Label Classes Constructors 5 (56.17 KiB) Viewed 44 times
Lab 8 24 C Artwork Label Classes Constructors 6
Lab 8 24 C Artwork Label Classes Constructors 6 (31.2 KiB) Viewed 44 times
Lab 8 24 C Artwork Label Classes Constructors 7
Lab 8 24 C Artwork Label Classes Constructors 7 (39.74 KiB) Viewed 44 times
Given main0, complete the Artist class (in files Artist.h and Artist.cpp) with constructors to initialize an artist's information, get member functions, and a PrintInfo0 member function. The default constructor should initialize the artist's name to "unknown" and the years of birth and death to -1. PrintInfo() displays "Artist:", then a space, then the artist's name, then another space, then the birth and death dates in one of three formats: - (XXXX to YYYY) if both the birth and death years are nonnegative - (XXXX to present) if the birth year is nonnegative and the death year is negative - (unknown) otherwise Complete the Artwork class (in files Artwork.h and Artwork.cpp) with constructors to initialize an artwork's information, get member functions, and a PrintInfo0 member function. The default constructor should initialize the title to "unknown", the year created to -1. PrintInfo, displays an artist's information by calling the PrintInfol) function in the Artist class, followed by the artwork's title and the year created. Declare a private field of type Artist in the Artwork class. Ex: If the input is: Pablo Picasso 1881 1973 Three Musicians 1921 the output is: Artist: Pablo Picasso ( 1881 to 1973) Title: Three Musicians, 1921 Ex: If the input is: Brice Marden 1938 −1 Distant Muses 2000

[\}]
\begin{tabular}{l|l} LAB & 8.24.1: LAB: Artwork label (classes/constructors) \end{tabular} Current file: Artist.h - Load default template... I/ TODO: Declare private data members - artistName, birthYear, deathYear
Current file: Artist.cpp - Load default template... 46
Current file: Artwork.h - Load default template...
Current file: Artwork.cpp - Load default template...