How do I call functions defined outside a source file given you shouldn't use header files?
-- EDIT: generic(?) question below
So, first, a problem should be broken down into simpler subproblems. Then, each subproblem is solved by implementing new code for a subsolution or reusing an existing subsolution. If done correctly, then each subsolution exists on its own, uncoupled to any other subsolution and called by the interface it provides. That is how I understand modularity.
To solve the superproblem, the sum of all subproblems, one central logic, the supersolution, brings together all the subsolutions and coordinates every subsolution such that the superproblem is solved.
If the solution scheme above is flawed, please clarify.
Now, how do you accomplish coding the supersolution in c++? Particularly, how can you reuse a subsolution for a different superproblem?
superproblem_1: isolate dialog in a novel's text file
possible subproblem_1: how to get text between quotes?
possible subsolution_1: split(novelLine, '\"')
superproblem_2: isolate dialog in a list separated by commas
possible subproblem_2: how to get text between commas?
possible subsolution_2: split(dialogList, ',')
common subsolution: split(string, character)
So, when you break up both superproblems, a common subsolution exists. If I made the programs modular, I can extract that common subsolution out of both. How can I then use the subsolution in both superproblems given that I just extracted it?