Learn to think in arrays, the APL way: ask one question of the whole field at once.
Write one APL function, Harvest. Every day it’s given today’s field as ⍵ and gives back 1s and 0s: 1 means harvest that plot, 0 means leave it. Score as much as you can in a season.
Learn to think in arrays, the APL way: ask one question of the whole field at once. New to APL? Play the tutorial.
God mode
Your field on day 1, ⍵
Showing what would harvest today: .
Days played0/100
Score0
Wasted0
Personal best–
⍵ is today’s field. Compare it with a stage, like ⍵=Ripe, to get a yes (1) or no (0) for every plot: Harvest harvests the 1s. The stages come in order: Seed, Sprout, Growing, Ripe, Rotten.
Harvest←{}
Scare←{}
Tap names, symbols and keys to build your code (on a tablet, ⌨ brings up the keyboard), or type symbols with a backtick prefix, so `w gives ⍵. Hover a symbol, focus it with the keyboard or press and hold it to see what it does. Dashed outlines preview what Harvest would pick today, without using up a day. Ctrl+Enter or ⌘+Enter moves to the next day. Tab indents; press Esc then Tab to leave the editor.