(Start disclaimer) New to ruby, new to rails, haven’t programmed since
high school. (End disclaimer)
I am working on a personal project which I can use to track my golf
scores and progress but am having difficult keeping a running count of
the amount of holes played.
The app should work like this:
- User starts the round - OK
- Hole number is set to 1 - OK
- User submits the first hole - OK
3a. Hole number is saved as 1 - OK
3b. Hole number increases by 1 - NOT OK
- Redirect back to new - OK
Repeat until hole number = 18
How can I create a variable which will store the hole number for the
number of user inputs? Or should I write a loop which runs the input
form # times?
Thanks for any advice.
(The basic code I am working off of is a (very) slightly modified