Hacker News new | ask | show | jobs
by meric 4067 days ago
You can use semi-colons in Python to put multiple lines in one line, as well as inline blocks next to the colon. So, you can remove the braces, too. Added parenthesis for python 3.

    當運:
      猜=整(輸('輸入數字: '))
      如猜==數:印('恭喜');運=假;
      否如猜<數:印('錯了, 再大');
      否:印('錯了, 再小')