Hacker News new | past | comments | ask | show | jobs | submit login

The 198 solution has the same problem. F cannot tell if the light is on because it was originally on, or G preceded F and the light started off. You're always going to be susceptible to off-by-one errors.



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: