I'm making a program that would essentially just be a manager for a record label (I'm just kind of making stuff up as I go along for fun), and I have a few classes. class RecordLabel, class Rapper, and class Album so far. Here's album:
using namespace std;
#include <iostream>
#include <string>
class Album
{
public:
void getAlbumName() const;
string setAlbumName(string);
void getNumTracks() const;
int setNumTracks(int);
void getTracklist() const;
string setTracklist(string);
private:
string albumName;
int numTracks;
string tracklist[];
};
So I'm just not sure about tracklist. My first idea was to use an array as you can see, but honestly I'm not sure what would be best. Could I use a linked list? Should I use an array of pointers? I've always been somewhat iffy on my knowledge of things like pointer arrays and lists so I figured this was a good opportunity to learn something.
Edit: I should be more clear: tracklist would just be a way to store the titles of however many tracks on an album.