TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Ask HN: Which programming games helped you become a better programmer?

84 点作者 gpa将近 3 年前
There are numerous programming games available that claim to teach you how to code. However, I couldn&#x27;t find any posts on HN that confirmed or denied their usefulness. Except this one, but it&#x27;s from 5 years ago: https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=13566247<p>1. Are there any good beginner programming games in widely used programming languages (like C, C++, C#, Java, JavaScript, Python, PHP)?<p>2. Are there any programming games that have helped you become a more advanced programmer (or a better programmer)?<p>I am interested in games that are not just fun, but also teach you programming useful in the real world (maybe not directly, since it&#x27;s a game, but still).

53 条评论

bobinux将近 3 年前
Well, I&#x27;ve enjoyed these games as for fun, but they did provide an intellectual challenge: TIS-100 <a href="https:&#x2F;&#x2F;store.steampowered.com&#x2F;app&#x2F;370360&#x2F;TIS100&#x2F;" rel="nofollow">https:&#x2F;&#x2F;store.steampowered.com&#x2F;app&#x2F;370360&#x2F;TIS100&#x2F;</a> SHENZEN I&#x2F;O <a href="https:&#x2F;&#x2F;store.steampowered.com&#x2F;app&#x2F;504210&#x2F;SHENZHEN_IO&#x2F;" rel="nofollow">https:&#x2F;&#x2F;store.steampowered.com&#x2F;app&#x2F;504210&#x2F;SHENZHEN_IO&#x2F;</a> Hacknet <a href="https:&#x2F;&#x2F;store.steampowered.com&#x2F;app&#x2F;365450&#x2F;Hacknet&#x2F;" rel="nofollow">https:&#x2F;&#x2F;store.steampowered.com&#x2F;app&#x2F;365450&#x2F;Hacknet&#x2F;</a> Uplink <a href="https:&#x2F;&#x2F;store.steampowered.com&#x2F;app&#x2F;1510&#x2F;Uplink&#x2F;" rel="nofollow">https:&#x2F;&#x2F;store.steampowered.com&#x2F;app&#x2F;1510&#x2F;Uplink&#x2F;</a><p>As for becoming a better programmer, it&#x27;s all about practice. CodeWars might be what you&#x27;re looking for: <a href="https:&#x2F;&#x2F;www.codewars.com&#x2F;" rel="nofollow">https:&#x2F;&#x2F;www.codewars.com&#x2F;</a>
评论 #31632812 未加载
评论 #31635410 未加载
评论 #31637174 未加载
madmax108将近 3 年前
Maybe not an exact answer to the question being asked, but when flexbox was first introduced a few years back, I remember being quite overwhelmed by it, but the game that helped me &quot;grok&quot; it was Flexbox Froggy: <a href="https:&#x2F;&#x2F;flexboxfroggy.com&#x2F;" rel="nofollow">https:&#x2F;&#x2F;flexboxfroggy.com&#x2F;</a><p>Even now, when I am working with frontend designs, I sometimes am mentally picturing my elements as frogs that need to be placed in the right place :D
评论 #31639955 未加载
评论 #31633251 未加载
heliophobicdude将近 3 年前
Factorio.<p>Factorio doesn’t exactly have code. However, it’s very much a game about systems, and how to efficiently build and manage them.<p>In fact, Shopify expensed the game for their employees [1]<p>1: <a href="https:&#x2F;&#x2F;twitter.com&#x2F;tobi&#x2F;status&#x2F;1294330081452666882" rel="nofollow">https:&#x2F;&#x2F;twitter.com&#x2F;tobi&#x2F;status&#x2F;1294330081452666882</a>
评论 #31635656 未加载
评论 #31638375 未加载
评论 #31633148 未加载
latency-guy将近 3 年前
If you&#x27;re willing to be charitible of where exactly programming comes in while playing a game - I would say creating cheats or bots for video games.<p>These days, you will most likely have your account restricted and banned from an entire ecosystem of games if you try this, but back in the days where flash was dominant you could do lots of fun things with little risk. Many fun times in Runescape making dollars off my bots that ran air runecrafting bots, or Fist of Guthix bots in F2P and selling the GP I got for the rewards. Does not need to be very complicated either IMO.<p>For a direct answer, I think Minecraft has a lot of options for learning programming without really learning programming. I have never played it but I have seen what others have done in what I believe is creative&#x2F;builder mode.
评论 #31633292 未加载
MarioPython将近 3 年前
2 games come to mind...<p>- Turing complete: helped me understand how a computer works, how binary works and what the instructions and operations look like at the hardware level<p>- Factorio: helped me understand broader aspects like availability, fault tolerance, decoupling, team management, prioritization.
QuadmasterXLII将近 3 年前
For 2, Codingame&#x27;s bot programming challenges are excellent. To get high on the leaderboards you need to write super well optimized code and have clever ideas, which is about as fun as a programming challenge gets. To get started, I&#x27;d recommend their TRON lightcycle game, which has a great combination of approachable ruleset and deep gameplay.<p><a href="https:&#x2F;&#x2F;www.codingame.com&#x2F;multiplayer&#x2F;bot-programming&#x2F;line-racing" rel="nofollow">https:&#x2F;&#x2F;www.codingame.com&#x2F;multiplayer&#x2F;bot-programming&#x2F;line-r...</a><p>If you prefer floating point math over integers, their pod racing game is awesome: at one point my algorithm was fourth in the world at it.<p><a href="https:&#x2F;&#x2F;www.codingame.com&#x2F;multiplayer&#x2F;bot-programming&#x2F;mad-pod-racing" rel="nofollow">https:&#x2F;&#x2F;www.codingame.com&#x2F;multiplayer&#x2F;bot-programming&#x2F;mad-po...</a><p>As a bonus, you can use just about any language you want: I know they have at least python, C, c++, rust, Go, Java, javascript, bash...
评论 #31633436 未加载
adamredwoods将近 3 年前
The inverse worked for me: I wrote a game to become a better programmer.<p>I recommend most beginners to start with a simple solitaire card game, make a polished card game, complete with tutorial, pausing, win&#x2F;lose conditions. The reason is the graphics and flow of the game are already a common thing, so planning it is minimal and the focus is on the coding.
Bondi_Blue将近 3 年前
The very best suggestions, such as Core War and the Zachtronics games, are already in this thread. One fun little gem that hasn&#x27;t been mentioned: <a href="https:&#x2F;&#x2F;www.unixgame.io&#x2F;unix50" rel="nofollow">https:&#x2F;&#x2F;www.unixgame.io&#x2F;unix50</a>
评论 #31651377 未加载
erkmene将近 3 年前
It doesn’t seem to exactly fit your description but Python Challenge (<a href="http:&#x2F;&#x2F;www.pythonchallenge.com&#x2F;" rel="nofollow">http:&#x2F;&#x2F;www.pythonchallenge.com&#x2F;</a>) has been incredibly fun and rewarding for me back in the day.<p>It’s a series of riddles that are meant to be solved using the python language. It’s really old now but I’m hoping that some library specific riddles are still relevant. Apart from those few, most of them should be language agnostic as well.<p>I’ve always wanted to create a similar thing to replicate the experience in JS but never gotten around to it.<p>Edit: oh also completely agree with most of the recommendations here. Particularly with TIS-100, Factorio and Human Resource Machine.
评论 #31633621 未加载
chaabani将近 3 年前
I’ve developed Recursive [0], a programming puzzles game that helps understand and master recursion, which is, I think, a topic that many developers have difficulty with.<p>I’ll be glad to send an AppStore promo code for those who’d like to play it for free (email in website [1]).<p>Also, I don’t use any analytics tools. So your direct feedback is welcome and highly appreciated.<p>[0] <a href="https:&#x2F;&#x2F;apps.apple.com&#x2F;app&#x2F;recursive&#x2F;id1550504475" rel="nofollow">https:&#x2F;&#x2F;apps.apple.com&#x2F;app&#x2F;recursive&#x2F;id1550504475</a><p>[1] <a href="https:&#x2F;&#x2F;www.kidori.com" rel="nofollow">https:&#x2F;&#x2F;www.kidori.com</a>
评论 #31633664 未加载
ttanev将近 3 年前
I&#x27;ll reply mostly on 2. - most of these were already mentioned in the previous thread - [0] Grasshopper, [1] SpaceChem (awhile ago), [2] 7 billion humans (haven&#x27;t finished it yet, and haven&#x27;t played for a while), [3] Human Resource Machine and [4] TIS-100. They mostly help to build habits, and persistency, not just being fun.<p>The &quot;real world&quot; always provides much more interesting &quot;gameplay&quot;, but it is sometimes with a too steep learning curve. :)<p>Edit: And I&#x27;ve been ninja&#x27;d by another user, but just remembered that there is another in my wishlist - [5] Baba is you (haven&#x27;t played it, though)<p>[0] <a href="https:&#x2F;&#x2F;grasshopper.app&#x2F;" rel="nofollow">https:&#x2F;&#x2F;grasshopper.app&#x2F;</a> [1] <a href="https:&#x2F;&#x2F;zachtronics.com&#x2F;spacechem&#x2F;" rel="nofollow">https:&#x2F;&#x2F;zachtronics.com&#x2F;spacechem&#x2F;</a> [2] <a href="https:&#x2F;&#x2F;tomorrowcorporation.com&#x2F;7billionhumans" rel="nofollow">https:&#x2F;&#x2F;tomorrowcorporation.com&#x2F;7billionhumans</a> [3] <a href="https:&#x2F;&#x2F;tomorrowcorporation.com&#x2F;humanresourcemachine" rel="nofollow">https:&#x2F;&#x2F;tomorrowcorporation.com&#x2F;humanresourcemachine</a> [4] <a href="https:&#x2F;&#x2F;zachtronics.com&#x2F;tis-100&#x2F;" rel="nofollow">https:&#x2F;&#x2F;zachtronics.com&#x2F;tis-100&#x2F;</a> [5] <a href="https:&#x2F;&#x2F;www.hempuli.com&#x2F;baba&#x2F;" rel="nofollow">https:&#x2F;&#x2F;www.hempuli.com&#x2F;baba&#x2F;</a>
评论 #31633523 未加载
optimalsolver将近 3 年前
Core War:<p>&gt;Core War is a 1984 programming game created by D. G. Jones and A. K. Dewdney in which two or more battle programs (called &quot;warriors&quot;) compete for control of a virtual computer. These battle programs are written in an abstract assembly language called Redcode.<p><a href="https:&#x2F;&#x2F;en.wikipedia.org&#x2F;wiki&#x2F;Core_War" rel="nofollow">https:&#x2F;&#x2F;en.wikipedia.org&#x2F;wiki&#x2F;Core_War</a>
评论 #31633446 未加载
robotburrito将近 3 年前
I never understood the point of games that emulate the programming experience. Whenever I play them I feel like I&#x27;m wasting my time and I could be making something real.
评论 #31634860 未加载
评论 #31633425 未加载
评论 #31635131 未加载
评论 #31633411 未加载
评论 #31633714 未加载
评论 #31635627 未加载
评论 #31633526 未加载
评论 #31633685 未加载
jamal-kumar将近 3 年前
I like CTF stuff. I tried this one called yolo space hacker:<p><a href="https:&#x2F;&#x2F;store.steampowered.com&#x2F;app&#x2F;1341450&#x2F;Yolo_Space_Hacker&#x2F;" rel="nofollow">https:&#x2F;&#x2F;store.steampowered.com&#x2F;app&#x2F;1341450&#x2F;Yolo_Space_Hacker...</a><p>I like it because now I have something gameified to recommend to people who want to break into computer security. It was REALLY easy for me as someone who&#x27;s been mired in that world for a long time, though I&#x27;m probably going to buy the other missions to see if they pose more of a challenge.<p>Make sure to download the performance DLC. It runs in a VM but it&#x27;s better off with virtualbox in my experience than the other options. Opt for compiled tools rather than old perl and python scripts if you want missions to go faster.
评论 #31633387 未加载
I_dev_outdoors将近 3 年前
Find yourself a MUD (something like www.dsl-mud.org), which is a text based DND type game, and start learning how to capture text and automate in game actions.<p>Just by trying to automate something like character creation rolls, you&#x27;ll learn a lot.
xtagon将近 3 年前
Playing Battlesnake has helped me become a better programmer. I&#x27;ve used it to gain experience in multiple new (to me) programming languages as a freeform way to practice without deadlines, I&#x27;ve learned new algorithms and how they apply to game solving, and I am beginning to understand how many game-solving algorithms can be applied to more practical applications since &quot;games&quot; in the game-theoretic sense can just as easily be models of real-world situations where the players are rational people instead of &quot;game&quot; participants. For example, &quot;pathfinding&quot; and &quot;decision making&quot; has many parallels.<p>Learning game tree searches such as minimax, MCTS and CFR is teaching me about tree&#x2F;graph algorithms and data structures, how to work with, reason about, and test explosive search spaces where the entire tree can&#x27;t be feasibly completely exhausted, in the process of researching these things I&#x27;ve learned to read whitepapers in the literature that would otherwise be scary to me as a developer and actually care to understand the math, it inspired me to tinker with Formal Methods including TLA+, and all the while having fun and making friends.<p>Learning Goal Oriented Action Planning, or GOAP (which I actually didn&#x27;t apply to Battlesnake in the end, but I never would have found it if I wasn&#x27;t looking) helped me optimize my real-world productivity by translating the concepts from game AI to personal task planning. In my head there is an analogy now between handling backlogs according to the current working context, and a GOAP-like stack based finite state machine. Learning a simple game algorithm helped me procrastinate less.<p>For newer developers, you&#x27;ll also out of necessity learn many real-world web development and ops concepts because the way Battlensnake works is that you run your own web server conforming to their move API. So you have to keep your snake AI up and reachable, responding to each request within the allotted timeout, and know the basics of HTTP on day one. Games can also run concurrently so you learn how to deal with concurrent games and whether to make them stateful or stateless between turns, which can be a different experience on different web frameworks&#x2F;languages and might teach you about things like threading or the actor model or distributed systems.<p>For advanced developers, there&#x27;s always somewhere to go next. Your snake AI can be anything from hard-coded rules to tree searches (as mentioned above) to deep reinforcement learning.<p><a href="https:&#x2F;&#x2F;play.battlesnake.com&#x2F;" rel="nofollow">https:&#x2F;&#x2F;play.battlesnake.com&#x2F;</a>
评论 #31648917 未加载
opheliate将近 3 年前
More applicable for kids, although certainly of interest to adults too: Minecraft. Any interest in Redstone will push players towards learning the basics of binary logic, without even realising what they&#x27;re learning will be applicable down the line. Plus, it has (I assume) the largest modding scene of any game - there&#x27;s a lot of people out there who have learned Java just so they can target Minecraft&#x2F;CraftBukkit.
kubi07将近 3 年前
OverTheWire wargames. I played first 10 levels, it&#x27;s kinda fun, kinda frustrating but it made me read manuals of &#x27;grep&#x27; and &#x27;find&#x27; commands on bash. So it made me a better programmer for sure. <a href="https:&#x2F;&#x2F;overthewire.org&#x2F;wargames&#x2F;" rel="nofollow">https:&#x2F;&#x2F;overthewire.org&#x2F;wargames&#x2F;</a>
terryp将近 3 年前
I feel like I&#x27;ve always gotten the most from Exercism. [ <a href="https:&#x2F;&#x2F;exercism.org&#x2F;" rel="nofollow">https:&#x2F;&#x2F;exercism.org&#x2F;</a> ]. It&#x27;s similar to Code Wars, in some ways, but I like the interface on the CLI, I like that you can get mentoring, I like that there are multiple languages.
js8将近 3 年前
I learned Forth thanks to Minecraft RedPower2 mod. Whether it actually made me a better programmer can be disputed.<p>I don&#x27;t think any game will make you a better programmer. It can get you interested, sure, but becoming a better programmer is only so much related to having in-game fun, and is often a matter of more self-discipline.
DylanSp将近 3 年前
I&#x27;m not sure if it qualifies as a programming game vs. a gamified way of teaching programming concepts, but I liked The Deadlock Empire for exploring concurrency issues: <a href="https:&#x2F;&#x2F;deadlockempire.github.io&#x2F;" rel="nofollow">https:&#x2F;&#x2F;deadlockempire.github.io&#x2F;</a>.
jstimpfle将近 3 年前
To the list of Zachtronics games, I&#x27;ll add Opus Magnum, which is the one that I found most rewarding.
评论 #31633692 未加载
gpa将近 3 年前
I&#x27;ve already mentioned it in another comment, but (being unable to edit my question already) this is what I was thinking when I asked the question: an addictive game with progressive complexity and (possibly) time-limited challenges that make you feel like you didn&#x27;t waste (hours of) time because of the knowledge (skills) you&#x27;ve gained.<p>I guess, I have to try some of the games that everyone has mentioned.
32kfjh23将近 3 年前
Check out flexbox froggy. There are good games about git too. I tried the Twilio games but I think those are better for young kids. It takes too long.
评论 #31632691 未加载
encrux将近 3 年前
Many good suggestions in here already, so I&#x27;m just gonna add Space Engineers.<p>It&#x27;s a voxel-based spaceship building game, where you can quite literally design your spaceship from scratch. If that&#x27;s not enough for you, you can interact with your creation by writing c#-scripts that are stored in physically accessible programmable blocks.<p>There&#x27;s also a large modding community you can get into.
lesam将近 3 年前
I started programming with “learn to program basic”, a series of animated programming tutorials in BASIC lightly disguised as a game.
dcchambers将近 3 年前
Not specifically programming, but I firmly believe that playing Roller Coaster Tycoon as a kid dramatically helped spur my interest in STEM and learning in general.<p>It was my first introduction to: physics, accounting and finance, data visualizations, and more.<p>Roller Coaster Tycoon 2 holds up remarkably well today, either natively or via OpenRCT2. Highly recommend it to anyone and everyone.
dllthomas将近 3 年前
Both are somewhat obliquely related to programming, but I really enjoyed incredible.pm and (the demo of) vim-adventures.com
Night_Thastus将近 3 年前
I highly enjoyed TIS-100 and Shenzhen-IO, though I&#x27;m not even close to completing either. They wouldn&#x27;t make you better at a specific language (even assembly, since they use a pseudo-assembly) but I think they&#x27;d be useful to get better at problem solving and breaking down algorithms into their most basic parts.
lcordier将近 3 年前
What about <a href="https:&#x2F;&#x2F;slate.com&#x2F;technology&#x2F;2014&#x2F;01&#x2F;robot-odyssey-the-hardest-computer-game-of-all-time.html" rel="nofollow">https:&#x2F;&#x2F;slate.com&#x2F;technology&#x2F;2014&#x2F;01&#x2F;robot-odyssey-the-harde...</a><p>Learn some boolean logic ;)
mjouni将近 3 年前
During my teenager years Colobot helped me cement a lot of the core programming concepts: <a href="https:&#x2F;&#x2F;en.wikipedia.org&#x2F;wiki&#x2F;Colobot" rel="nofollow">https:&#x2F;&#x2F;en.wikipedia.org&#x2F;wiki&#x2F;Colobot</a><p>The syntax is very C++&#x2F;Java-ish.
michaelrpeskin将近 3 年前
ZZT. It’s one of Tim Sweeney’s (Of Epic fame) early games.<p>It was my intro into true OO programming. You program literal objects to interact by message passing.<p>You should be able to pick it up all over the internet. It’s abandonware but has a pretty good community.
Threeve303将近 3 年前
Trade Wars 2002... A popular old BBS door game with many scripting options to automate trading and many other aspects of the game. Also when I started getting into hacking and exploits. MajorBBS was a lot of fun in that regard.
Stevvo将近 3 年前
There are plenty of games that helped me become a better programmer, but none of them were programming games. You can choose games you enjoy that are open to modding and have your fun programming mods.
Claude_Shannon将近 3 年前
I got more confident in my Assembly skills after playing a lot of TIS-100.
damagednoob将近 3 年前
Not programming games but Starcraft and Quake (keys set to esdf instead of wasd). They taught my left hand where to be on the home row and I credit them for indirectly teaching me touch typing.
Apreche将近 3 年前
Does Advent of Code count?
评论 #31633107 未加载
breckenedge将近 3 年前
Any game that supports extension via modding is a potential to learn more about programming. I think when programming is the game, it’s kinda boring and feels too much like work.
mdp2021将近 3 年前
Let us also remember that before programming:<p>The NAND Game, nandgame.com<p>is &quot;obligatory&quot;.
defterGoose将近 3 年前
MHRD. Cool little game about Hardware Description Languages. Takes you from designing basic logic gates all the way up to a microprocessor.
jleyank将近 3 年前
Super Star Trek, chess and Conway’s game of life. Taught about code size and efficiency and how to tailor the approach to the problem.
hitpointdrew将近 3 年前
While this game doesn’t teach you to code, I would argue that Portal (1 and 2), teach you how to solve programming like problems.
beprogrammed将近 3 年前
<a href="https:&#x2F;&#x2F;www.pwnadventure.com" rel="nofollow">https:&#x2F;&#x2F;www.pwnadventure.com</a><p>LiveOverflow did a series on it
jmconfuzeus将近 3 年前
If you want to learn assembly or how computers work at a lower level, play TIS-100 by Zachtronics.
e9将近 3 年前
www.codecombat.com is focused on kids but I found it great for beginners in general. You can choose to learn JavaScript or Python. I had a lot of fun watching and helping my gf go from 0 to being able to write basic JavaScript.
jzellis将近 3 年前
Goretek and the Microchips, but y&#x27;all probably a little young for that. :-D
gediz将近 3 年前
I think some of the Zachtronics games may be helpful to learn about Assembly.
itake将近 3 年前
leetcode.com is an interesting puzzle game and is language agnostic.
jayski将近 3 年前
the game of having bills to pay.
styluss将近 3 年前
The Typing of the Dead
pdenton将近 3 年前
Kids these days...<p>Go read a book!
syngrog66将近 3 年前
the programming game
lordkrandel将近 3 年前
None