What can be worked out from the specification is that "startYear" and "endYear" are values entered by the user for processing (and will be variables in the code), and a "range of years" which means going from "startYear" to "endYear" by one year at a time. All the variables will be integers.
This means a loop.
There are a couple of choices. One obvious choice is a "Do While(condition)" loop that has a variable set at the "startYear" and with a "startYear = startYear + 1" within the loop, with the loop finishing when it reaches the "endYear". Something like this:
But that's not the only choice available. Because the loop is increasing the years by one every time, a simple FOR NEXT loop will work just as well.
prompt user: "please enter a start year for the leap year range calculator"
(get startYear from the user)
prompt user: "please enter an end year for the leap year range calculator"
(get endYear from the user)
Do while (startYear <= endYear)
COMMENT: leap year logic goes here
startYear = startYear + 1
end loop
FOR NEXT loops don't have to start from zero (or even one for that matter). They just need some continous range of values and they will automatically loop and increase until the end condition is met.
prompt user: "please enter a start year for the leap year range calculator"
(get startYear from the user)
prompt user: "please enter an end year for the leap year range calculator"
(get endYear from the user)
FOR thisYear = startYear to endYear
COMMENT: leap year logic goes here (using thisYear to process)
NEXT