r/tinycode • • Dec 07 '24

Game "Goldmine" in 200 lines of pure JavaScript

https://slicker.me/javascript/gold/goldmine.htm
21 Upvotes

2 comments sorted by

View all comments

Show parent comment

5

u/swe129 Dec 07 '24

I appreciate your feedback!

My code is much longer than what you guys usually post in this subreddit (it's probably at least a couple of kilobytes vs your ~60 bytes), because it's not code golf. I went with the "1 line = 1 instruction" definition and could definitely trim it down by not declaring variables etc and sacrificing readability. But I'm glad it's compact enough to earn your upvotes.

I'll definitely check out js1024.