无聊的时候在PyCharm上想找一个游戏相关的插件,输入game之后弹出了神奇的snake……
官方的解释是这样的:
A snake game inside your code structure in IntelliJ.
Make your code more Python-like by helping the snake eat all the curly braces and semicolons!
To start the game type ‘snake’ in the editor or use “Tools | Run Snake” action.
也就是说为了让你的代码更Python化,snake会帮你吃掉分号和大括号,可以直接在代码里敲”snake“或在Tools里启动。
Just for fun……
重启了PyCharm后,在代码任意处敲”snake“就可以启动了,会在上方出现个小黑条,键盘方向键控制方向,的确可以吃分号和大括号,撞到其他代码或边框game over~
回车可以暂停或重来,ESC退出,但不知道为什么第一次启动失败后会卡住,重启后正常。。。
Just for fun~