This week's book giveaway is in the OO, Patterns, UML and Refactoring forum. We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line! See this thread for details.
Sorry about the unspecific title, I'm having trouble wording what my issue is because I don't really understand what I'm having trouble with.
I'm currently running through the courses at programmingbydoing.com and everything is going well. Unfortunately I've run into a problem I can't get past.
THIS ONE SPECIFICALLY.
It's asking me to pass an int (lets call it currentKeys) from main() to add_keychains(). That function call will execute a few line prints and ask how many Keychains I would like to add to the total and take the user input. Somehow I have to take that and add it to the currentKeys variable that is stored in the main function (I have no idea how to do that), and then return the new total.
I'm not sure if I am simply misinterpreting what he's saying or not. I don't want to use some unintended method of doing so or use a way he hasn't taught me yet. So far I feel I genuinely understand everything he has taught so far. I understand why I have to use these things and how/when to. So I don't wanna "cheat" my way through this one, I just need help understanding it.
I'm sorry if I wasn't very clear, just ask if you need clarification on anything.