Coding and programming on Linux

super_user_do

Member
Joined
Apr 23, 2022
Messages
96
Reaction score
41
Credits
714
Hello everybody :)
I want to learn some programming languages, especially Java and C. What would you recommend to use for a beginner? How do I compile and execute the code?
 


Online tutorials, you tube demos, or search for
a book on the language you are interested in.
 
Last edited:
Hello everybody :)
I want to learn some programming languages, especially Java and C. What would you recommend to use for a beginner? How do I compile and execute the code?
The C Programming Language (Kernighan & Ritchie) and The Java Tutorial (online here) are the best books to start in my opinion.

The second one has been written for Java 8, and though you would have to get some updates in some language characteristics to make the most from current versions, it’s conceptually very good to start.
 
Use any Linux distro you like.
They're all made by programmers, for programmers - all of the programming tools you'll ever need are available in the repos of all disros.

When it comes to compiling and executing code - there are a number of ways to do it.
You can either do it in the terminal using compilers like gcc/g++/clang/clang++, (or javac for java) and use make-files, or a build system like apache-ant, CMake, ninja etc. for building your programs.
And use debuggers like gdb in the terminal for testing/debugging.

Or you can download and install an IDE like Code::Blocks, VSCode, QTCreator, KDevelop for C/C++
Or Eclipse for Java, or Android Studio for Java programming for Android devices.
There are other IDE's available for other languages. It's also worth noting that some IDE's can be used for multiple languages.

An IDE is basically a text editor with a bunch of additional features that allows you to quickly set up a project, it integrates with your compiler/linker (gcc/g++/clang/clang++) and your debugger (gdb) and has other useful functionality. This integration allows you to be able to build, run and debug your programs from inside the IDE. As a beginner - you'll almost certainly want to install an IDE for whatever language you want to learn.

Once you have a better idea of what you're doing in an IDE, you might then decide to try using the compiler directly from the command line and start using make-files, or one of the many build-systems to build from the terminal.

It is definitely worth learning a bit about compiling and debugging your programs using the compiler/linker and debugger in the terminal - if nothing else, it will make you appreciate all of the neat things that an IDE automatically/automagically takes care of for you in the background!
 
greenfoot is a great app to learn java with.
edx has many free courses.
 
Once you have a better idea of what you're doing in an IDE, you might then decide to try using the compiler directly from the command line and start using make-files, or one of the many build-systems to build from the terminal.
Whats the difference between the two? What IDE would you recommend to an absolute beginner?
 
C, C++ and Java are all cross platform, and very well documented and capable. For ease of learning, I would recommend Java > C++ > C.

Sticking with open source, I like Code::Blocks for C/C++, and Eclipse for Java.

If you're ok with proprietary IDEs, and you're familiar with Visual Studio, VSCode isn't a bad environment. However, in Microsoft fashion, VSCode does "call home" and send telemetry by default.
 
C, C++ and Java are all cross platform, and very well documented and capable. For ease of learning, I would recommend Java > C++ > C.

Sticking with open source, I like Code::Blocks for C/C++, and Eclipse for Java.

If you're ok with proprietary IDEs, and you're familiar with Visual Studio, VSCode isn't a bad environment. However, in Microsoft fashion, VSCode does "call home" and send telemetry by default.
Code::Blocks seems fine to me. Do you think I should use another compiler than GCC?
 

Members online


Top