Coding Snake in 4 min 30 sec (plain browser JavaScript)