Python is pretty easy to pickup and super popular so there are tons of guides and libraries to help get the job done. It does have a library called PyGame but honestly it is not super powerful, however there is a FOSS engine called Godot that uses what they call gdscript, which is very similar to Python.
Programming
All things programming and coding related. Subcommunity of Technology.
This community's icon was made by Aaron Schneider, under the CC-BY-NC-SA 4.0 license.
I heard about pygame, I was hopeful but oh well. I also heard about godot but I didn't know if it was similar to something else.
If you decide to look at Python, I really enjoyed going through the "Automate the Boring Stuff with Python" lessons/book. It breaks it down really well in non technical terms and I thought the work was pretty fun. It may be a good way to get a feel for it. I think once you learn one language it's a bit easier to pick up your next one (at least that how it went for me).
I heard that about learning a second one from other people too, and I think I heard this applies to languages in general, not just programming, but "people languages" too if that makes sense. Thank you for the suggestion mate, I'll definitely consider the book.
I used this book to teach a course. It definitely encourages you to think of programming as a means to an end, and not a skill in and of itself. That is completely fine IF that is what you want, and from your post, it sounds like it is.
If you find you'd like to dive a little deeper, I enjoy the Think Python book as a more "mathematical" and "rigorous" introduction. That doesn't mean it's harder. It just means it has a different approach and end goal!
If you want to make simpler games, you could start with scratch or stencyl. These tools aren't really programming languages per se but they let you build programs out of blocks that are much easier to visualize and play around with. There's some research that suggests they are good entry languages and some research that suggests they aren't, so ymmv. I've used both, but I knew how to program already.
For the record you shouldn't let "usually made with" drive your decisions. Java is still popular for some games. Slay the spire, a very popular deck building game, was written in Java, which is a decently popular choice if you want to support modding. But C++ and C# are more popular simply because that's what you use if you're using engines like unity or unreal.
side note: C, C++, and C# are all different languages.
I knew they are different but I also assumed they're at least similar, is that a wrong assumption? Will learn one make little difference if I learn another after?
Learning how to program in any language will make it easier to pick up any other language, because the main burden for a beginner is how to think programmatically. However once you're enough past that wall, being an expert on one language will mostly only help pick up languages that are similar. So if you knew C++, you could pick up the syntax and probably most of the semantics of the others very quickly, because they are similar in that regard. But you'd still probably struggle to actually program in C, because C is lower level (has way fewer features) than C++.
Technically speaking, C is a subset of C++. But that doesn't mean being a good C++ programmer automatically makes you a good C programmer.
C# is similar to the other two in syntax as well, but it's much more like Java than either of them.
Check out exercism.org - it has sequences of projects in increasing difficulty level in 66 languages. It is very user friendly and provides nice structure for getting started, without the pressure and stress that a classroom environment might introduce. As for the language, pick whichever one interests you.
I think C# was easiest for me to learn. I'll go a bit against the grain and say python was more challenging for me in particular. Setting up interpreters and using pip and venvs wasn't my thing, but you may have no issue.
That's interesting how for some people the same languages can be the opposite. Maybe I'll start with one and if it goes poorly I'll try the opposite side.
I can recommend Python, Lua or JavaScript. All are interpreted languages so you don't have to worry about setting up a build step, and the languages are solid and should be possible to learn without prior experience.
If you want to make games, don't worry about learning a specific programming language at first. You can transfer your skills pretty well when it comes to programming.
And if you are stuck you could try visual languages like MakeCode or Scratch.
Thank you, it's pretty encouraging to consider that skills transfer relatively easy if I do decide to move onto something else, it's not something I considered.
I would highly recommend python. It's fairly simple syntactically, which makes it less overwhelming someone who's just looking at code for the first time. It doesn't force you to learn about functions and classes right away, like other languages would, so you can focus on the real basics until you're ready to tackle the more abstract stuff.
The fact that it's on the 'simpler' side doesn't make it any less powerful, either. It's one of the top languages used for neural net AI and data science. It's also really great for throwing together a spur of the moment script when inspiration strikes, to automate a really boring task, for example. And yes, you can also make games with it.
Plus, the fundamental concepts that you use to solve problems with python are mostly the same in every language, so once you get proficient in one language, you'll be able to pick up other languages much easier.
Whichever language you do end up choosing, good luck on your journey!
Thank you very much for the post and the good luck :) Python does seem to be the most recommended language in the thread so it's likely I'll go for that, I'll take a loot.
Another C# gang comment here.
I'll try not to repeat what others said.
C# has one of the best debuggers in the industry. Debugger is a thing that lets you stop your program at a set state and investigate values of variables in that state. Very useful for education. The thing is incredibly easy to set up in Visual Studio right out of the box and is a matter of installing another extention in VS Code.
C# is in C syntax family, which includes C, C++ and Java. While you'll have to learn some syntax quirks to switch languages, they are not as drastically different as Python, for example. If your intention is getting into game development, setting a base for C++ is a nice bonus.
C# is strictly-typed. Unlike Python, Lua or JS that I saw in this thread, C# requires you to specify types of your variables. While it may sound as a disadvantage at first, it is actually extremely useful catching silly mistakes. Like if you make a string and pass it to a method that expects integer, C# simply won't compile, you'll have to explicitly convert your string to integer. JS is notorious for it's ('b' + 'a' + + 'a' + 'a').toLowerCase()
> "banana"
, which is extremely hard to follow if you're learning the language IMO.
If you're trying to build games with big game engines like Unity or Unreal Engine, C# is a no-brainer, as they support it natively. Godot has it's own language, but it has an option to switch to C#, so, you can cover all of them with one language.
Windows Forms. It's a package for developing GUI applications on Windows. Visual Studio comes with it and has a designer for it. If you want to learn how to make a simple GUI application, that's one of the easiest routes. Worth noting, if you're not on Windows, that thing is not that easy to use.
Here is an official "get started" guide: link.
Another great point about C# is the Documentation Microsoft provides. It covers concepts, most functions and types, is detailed and has mostly good example code. There are also a lot of good tutorials around.
The dependency management is a bit less intuitive than it is for python, but still less work that for C++.
Python is easy to learn and marketable. I personally prefer Ruby to Python, but Python is a good place to start. For most AAA games, it’s C++, and yes it’s horrendously complex. I vastly prefer Rust to C++. Good old C is actually a fairly small language, and only moderately difficult.
Thank you for your post, before this thread I thought that all the C named languages (c, c++ and c#) were at least similar but it looks like it's not the case.
They share a genealogy, but as programs are created and maintained in different languages, developers come to wish for different syntaxes that would (1) reduce how much code must be written to accomplish a common logical task, (2) make the code that's written easier to read/understand, (3) reduce concerns about variable types until runtime, and/or (4) overly restrict not just the variable types but also if/when variables can be modified. This list is not exhaustive.
There is a partial programming language family tree here, showing which languages influenced other languages: https://www.researchgate.net/figure/Genealogy-of-Programming-Languages_fig36_260447599
C derivatives are similar in terms of things like imperative control flow, lower-case keywords like if
, mostly insignificant whitespace, { }
-delimited blocks, etc., but they can be vastly different in terms of features, semantics, idioms, and typical use cases.
It's like how non-programming languages can use the same Latin alphabet but be vastly different in terms of grammar and culture.
I suggest learning Ruby, it's a lot nicer and easier to learn than many others in my opinion. You can learn Crystal at the same time, it's got very similar syntax but it's a compiled language so super fast.
Thanks, ruby was another language I saw in the thread popping a few times, the first one being python. I I was told a few things python can be good for, can you give me a few examples of good uses for ruby just to have a vague idea?
Ruby and Python are applicable in most of the same areas. I'm currently working on a realy simple Ruby project and using a web framework called Sinatra (kinda like a lightweight Ruby on Rails if you've heard of that) that makes it super easy to build web apps and APIs. My ruby app basically queries an API, sorts some data and presents it to my companies management as they need it.
Python is great too and more popular, thought I'm not really a fan as I don't like when languages enforce white space. Python also tends to have an "attitude" like there is only one way to do a task, whereas Ruby is more flexible in this respect. Also, Ruby is fundamentally "object oriented" , Python has some object orientation but it was added on as an afterthought so Python can be a bit mixed depending on which libraries you choose to use.
If you don't know what object orientation is, it means "everything is an object". In functional languages you'd count the letters, in Ruby you ask the object for it's length property.
This is Ruby, using the IRB command line interpreter (shell)
irb(main):001:0> word = 'bicycle' => "bicycle" irb(main):002:0> puts word.length 7 => nil irb(main):003:0>
If your intention is to make games, I reccomend Gamemaker Studio 2. If the pricing model is something you're not willing to work around (and trust me im still kinda salty about the change so i get it) Godot seems to be the move for 2d development.
GMS2 works on its own scripting language called Gamemaker Language, or GML. I'm told its similar to JS kinda. I used to redirect people to the r/gamemaker discord, but if you're in the fediverse that might not be something you care to do. The community there rules though and is always happy to help people learn.
I think Godot is on c#? I haven't used it yet, but it's open source so if that's important to you go for it.
Personally, I use Unity3d now, but I wouldn't reccomend jumping right into that. C# can be kind of challenging (but highly rewarding once you know what you're doing. serialized variables ftw)
My main focus is to learn a programming language, I tend to work better when I know I can do something fun and making games seemed like as good a goal as any other since I do play games a lot. I feel like the satisfaction of being able to see my sprites move would be an incentive, but it's definitely not my main end goal, just a nice side effect.
Try out Godot. It uses a really simple language (gdscript), has excellent learning material, and you can make games!
If you're coming into programming from zero, try Hedy.
It's a gradual progression textual programming language specifically designed for teaching and learning. At the last level of progression, it's just Python. The link above lets you get started right away in the browser with no setup, in your native language (English or otherwise).
If you're not coming from zero, you might want to jump a little deeper into C#, considering your goal of making games and the ecosystem of Godot and Unity. C# has a higher "low bar" of strictness and structure, which can stumble "from zero" learners.
My first programming language was QBasic, then Visual Basic, then Java, then C# (most experience with), then C++, then Python, and now Rust. Only when I learned C++ in college did I truly grasp the power of memory management. I think it's important for new programmers to have some understanding of and experience with pointers, but it doesn't need to be your first language. I think it's okay to start with Python or C#, but you'll want to go back and learn the hard stuff at some point (C++ and then Rust). Python will be super easy to learn the basics (data structures, algorithms, etc.). C# is also a good choice, but has you learning a few more things at the same time you're trying to learn the basics.
I would 100% recommend anyone who is serious about programming to learn C first. The syntax is very simple and the language is pretty easy to use. It also gives you a peak under the hood at how all programming languages work because it exposes a lot of control to you.
If you are intimidated by the difficulty of C (which I don’t think you should be — the hard one is C++), start with whichever language matches your interest:
Web dev: JavaScript Game dev: C# AI: Python
But also, remember that a programming language is just that. A language you use to express your ideas. A skilled, highly employable developer will know many languages even if they only use one at their job. Always seek new information and try and advance your learning. The syntax of a language is a pretty minor part of the journey overall and the least important part for a beginner. It’s all about learning how to think and how to express complex processes in a way the computer understands. The language just tells you what words to use once you can already do that.
Games can be written in literally anything—if that's your primary interest, you might want to look into Lua and Love2D, or Python and pygame (as has already been suggested). Both Lua and Python are good beginner's languages—Lua because it's small but versatile, Python because it's popular for that purpose and has good tutorials.
C# . . . isn't a bad language, but it's a bit bloated, so I wouldn't choose it for a beginner—save it for when you're proficient and looking for a second or third language. Other languages I would not start with would include Javascript and PHP (because both have hidden inconsistencies that can trip you up), Perl (I love it, but it looks like line noise half the time), and C and C++ (manual memory management, which makes a lot more work for you with no real benefits unless you're writing an OS kernel or something).
What you need to do is learn to think like a programmer, regardless of language. Anyone who's been programming for ten years or so will have gone through several languages as their needs change.
I feel like that all the time! I like Python, I find it fun and easy to dip your toe into. Hope you find something!