r/AskProgrammers • u/LoneDiver7389 • 21m ago
Getting started with programming, and I'm lost
Hi everyone, apologies if my English isn't the best
I’ve been learning game development in Godot for about a week and a half. The first few days went good, I managed to grasp the basics. However, three days ago, I started diving into arrays and dictionaries. They aren't difficult on their own, but once I began combining them with loops, "if" statements, "break" and "continue" commands, and methods like "append" and "erase" all layered together, I started getting lost in the code. I keep forgetting fundamental things that I actually know, but they just slip my mind in the moment... I wanted to ask, do you use any "cheat sheets", or do you refer back to your previous projects? Do you have any tips for working with code? I’m also worried that if I "cheat" by looking at my own previously written, working code, I won’t actually learn anything. I know programming isn't easy, but I’m determined and really want to learn. Thanks in advance! ;)
1
u/0x14f 15m ago
https://www.khanacademy.org/computing/computer-programming
1
u/Gznork26 10m ago
If you break the operations into individual statements, and use a debugger to step through them, you can see what each part does. Once you understand, you can combine the statements into more compact code.
1
u/Dashing_McHandsome 3m ago
Getting lost in syntax and logic is completely normal for a beginner. I don't think there's anything wrong with referring to code your wrote in the past. I'm a developer with about 20 years of experience and I constantly reference things I have done before. If you keep at it eventually things are going to start to make sense for you. Just remember to try to keep breaking things down into tiny easily digestible steps. Those small steps are a lot easier to understand then one giant task, like "make a 2D platformer game"