Jump to content

Should I Learn C, C++, Go, or Rust?


pacman9090
 Share

Recommended Posts

I know C and C++ are two fast, efficient, and mature computer languages that can be used to create operating systems, applications, and games. Are Go and Rust, two fast and efficient computer languages, that are also less mature than C and C++, good, if not better, alternatives, when it comes to speed and efficiency, for programming operating systems, applications, and games? I also know C++, Go, and Rust are considered modern computer languages, while C is not.

Link to comment
Share on other sites

If your goal is to be "that" guy... The one that software engineers fear and gossip about when you arrive at the office, you'll want to go with C to start. You'll also want to learn x86/64 Assembly and LOAD your C applications up with unnecessary functions written in Assembly for the purpose of speed.  When you create your GitHub account, you'll want to create things in Lisp, Cobol, and Fortran (mention that its for fun). You'll want to post random rants on your twitter about how C++ is TRASH, treating it like a disease that needs to be eradicated.

Go and C# are fun and pretty cool too. At some point you'll realize its ALL bullshit and doesn't even matter any more what you're using.

Link to comment
Share on other sites

Use the right tool for the right type of work you intend to do.

If you want to write end-client Windows applications (freeware,shareware,commercial, sold to individuals or companies) then you should consider using C/C++/C#/C++ Managed

If you want to develop front-end web-server applications (installed on a virtual hosting service) then you should consider using PHP (it will generate HTML, eventually CSS, eventually JavaScript, eventually other file-formats). PHP is installed on all/most virtual hosting services (other technologies are not)

If you want to develop back-end web-server applications (installed on a dedicated server) then you should consider using Bash, Python, Perl, CGI (obsolete, it's compiled C/C++), jNode (server-side JavaScript) and endless list of new technologies. Actually, you can use any language to generate HTML/CSS/JS for users (visiting WWW), because you own the dedicated server and can install anything (unlike virtual hosting, where you are limited to the software installed by the IT company where you bought the hosting).

If you want to develop applications for smartphones then you should learn (Android) Java, Kotlin, (iPhone) Swift.

 

To start, install Visual Studio Community

https://visualstudio.microsoft.com/pl/vs/community/

and use one of many template projects.

 

1 hour ago, rathlin said:

You'll also want to learn x86/64 Assembly and LOAD your C applications up with unnecessary functions written in Assembly for the purpose of speed. 

Nowadays, people use GPUs (OpenCL,CUDA) to accelerate applications.

 

Edited by Sensei
Link to comment
Share on other sites

Thanks, rathlin and Sensei. I was leaning more towards C and C++ to start because they are fast, efficient, and mature, meaning they are well documented and supported across platforms, which would make them perfect languages for creating games. Rust and Go both seemed like more modern choices, C++ is also modern, but C is not, but I was afraid all those modern features would slow down C++, Rust, and Go. I also have an interest in learning about technologies like Raylib, SDL2, OpenGL, Vulkan, and DirectX 12. C is an easier language to learn than C++, so I would normally prefer beginning with C, over C++, but C++ is considered better for game development, while C is better for OS kernel development than game development. There is just so much to consider.

Link to comment
Share on other sites

1 hour ago, pacman9090 said:

Thanks, rathlin and Sensei. I was leaning more towards C and C++ to start because they are fast, efficient, and mature, meaning they are well documented and supported across platforms, which would make them perfect languages for creating games.

People use Unity and Unreal engines to develop games. They are indeed written in C/C++. But do you ("beginner") really want to make your own game engine? I don't think so.. Having such heavy projects at the beginning of the journey would most likely put you down..

Scripts that extend game engines are usually written in C# and Python.

These days, to make a game you need 3D assets and/or 3D gfx artists, and almost no programming skills.

1 hour ago, pacman9090 said:

Rust and Go both seemed like more modern choices, C++ is also modern, but C is not, but I was afraid all those modern features would slow down C++, Rust, and Go. I also have an interest in learning about technologies like Raylib, SDL2, OpenGL, Vulkan, and DirectX 12. C is an easier language to learn than C++, so I would normally prefer beginning with C, over C++, but C++ is considered better for game development, while C is better for OS kernel development than game development. There is just so much to consider.

C/C++/C#/Java is 75-90% the same stuff. Unless by "learning language" you meant "learning built-in and 3rd party libraries/modules/extensions". Really, you find out what libraries are available when you create a project. For example, you need to open a file, you search the web for "how to open a file in [the language you are writing the project in today].". You can't learn all the methods/functions from all the libraries in advance, because programmers (counted in the tens of thousands) create these libraries faster than you can read them.

Really, start writing program, instead of talking about it.

For example, follow this tutorial ("how to create a calculator in C#"):

There are many such tutorials:

https://www.youtube.com/results?search_query=how+to+create+a+calculator+in+C%23

The difference between this C# code and C++ Managed (C++ which uses .NET Framework) is marginal (99% the same).

 

Edited by Sensei
Link to comment
Share on other sites

2 hours ago, Sensei said:

Scripts that extend game engines are usually written in C# and Python.

..are used to simulate bots/AI..

not for rendering graphics or anything like that (extensive processor)..

 

Link to comment
Share on other sites

Thanks for the info, and C# calculator coding tutorial, Sensei. Unreal and Unity are great game engines, but they are not completely free. Godot would be better for me. I was interested in coding a game engine and games in C, C++, and Raylib. C and C++ are fast and efficient, so they are perfect for coding games. JavaScript, Python, Java, and C# are slower and less efficient than C and C++, but they are easier to work with when coding games. I was also interested in eventually creating my own game engine and games in C, C++, OpenGL, and Vulkan, but that goal is a bit ambitious for me, at this stage in my coding development.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.