I have a feeling I’m stuck in tutorial hell, and I need to start actually building things. But I don’t know where to start :/

Also I’m really bad at syntax. I only know concepts like for loops, while loops, if-elif-elses, etc…

So maybe something that helps me learn more about coding syntax would be helpful.

Thanks!

  • Fargeol@lemmy.world
    link
    fedilink
    arrow-up
    5
    ·
    23 hours ago

    It was a tiny TicTacToe server I made to learn machine learning. I basically played TTT against it and it would train on the former games to improve. It didn’t work since I’m not a data scientist, but at least I know how to create Web Sockets!

    I can give you a few advice if you want

    • Single Responsibility Principle: don’t do everything in the same place, separate between functions, classes or files. In my server, one file contained anything related to the server, another anything related to game logic and another anything related to machine learning.
    • Don’t reinvent the wheel: unless you’re making it as an exercice, don’t create something that already exist as a library. Python is wonderful for its libraries
    • Don’t optimize stuff: if you feel that “it could be faster”, either benchmark it or give up. “Premature optimization is the root of all evil”
    • Learn how to make useful naming, tests and documentation: this is not something developers like to do but you’ll love yourself if you read your code after a few months
    • Don’t code with an AI: If you’re bad without an AI, you’ll be bad with it. If you’re good with an AI, you’ll be good without it. You can still ask one for snippets or use it as a tool to discover concepts you don’t know about but I strongly advice against autocomplete and coding agents (I talk from experience).

    If you don’t know how to start, you can make a really simple Tic Tac Toe game with its rules and play it in a CLI. Then you can decide how to pimp it: a better interface, game saves, an opponent played by the computer, a game server for a multiplayer game… you decide!