Hello I'm writing a program that reads in data from a file to create an array of clients and stocks.
I completed my client class and stock class. I'm stuck on my driver.

Screen_Shot_2019-12-02_at_11_53_13_PM.png

This is what I have it prints the text file but where would I include the array its part of the project?
I would love any feedback.

In general you would use another class to represent the set of all Clients, eg "ClientBase".
It would have public methods like addClient, printClients, printClientsSorted etc.
Internally it may hold those Clients in an array, or ot may be that some kind of List or Map works better, but by encapsulating it in a class you are free to change the internal implementation without affecting the rest of the program.
(this is the same logic as havimg a Library class to hold all your instances of Book)

Your driver class should never hold implemention logic like this - it shoud just call public methods of your application classes.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.