Review your favorite Linux distribution.
Go Back > Forums > Non-*NIX Forums > Programming
User Name
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.


  Search this Thread
Old 01-03-2004, 04:57 PM   #1
Registered: Dec 2003
Location: England
Distribution: Ubuntu
Posts: 71

Rep: Reputation: 15
Programming languages on Linux?

I'm getting into Linux and really trying to learn the ins and outs of it. I also want to do some programming, so I've been toying with learning some languages for Linux. Unfortunately, they're making us learn Visual Basic at school which isn't much use to me. At the moment, I know a bit of C++ and Python, what other languages are good for me to learn for use on Linux?

Also, I understand that the Linux Kernel is programmed in C. If I learn C++, what extra do I need to know to distinguish between C++ and C? how are the two different?

Ok, thanks.
Old 01-03-2004, 05:07 PM   #2
Registered: Nov 2003
Location: Slough, UK
Distribution: Debian
Posts: 146

Rep: Reputation: 15
C++ is an Object Orientated Language whereas C is procedure based.

If I were you I would learn C. Its extremely similar to C++ and most Linux/Unix programs are written in C.
Old 01-03-2004, 05:08 PM   #3
Registered: Feb 2002
Location: Grenoble
Distribution: Debian
Posts: 9,578

Rep: Reputation: 191Reputation: 191
You can try C, Perl, shell scripting..
Old 01-03-2004, 06:29 PM   #4
Registered: Jun 2003
Location: Durham, UK
Distribution: Slackware 9, Mandrake 9.1
Posts: 163

Rep: Reputation: 30
shell scripting is probably very different to what you have done before, so you could try and learn your way around the BASH shell. Perl is a unix 'glue' language, and so could be useful to look at. I dont like Perl at all myself, but il learn the ins and outs of it eventually.

C++ is an OO language, wheras C is purely procedural based. Syntax wise they are the same, and any C code should compile with a C++ compiler (such as g++). I learnt C++ before really doing much with C, but i dont think it matters too much which way you do it

As for other languages to look at, have a look at Java. Syntax like C++, however totally Object Oriented and cross platform

EDIT - changed gcc to g++, must have been tired when i wrote that, thanks Strike

Last edited by Tesl; 01-04-2004 at 11:03 AM.
Old 01-03-2004, 10:11 PM   #5
Registered: Jun 2001
Location: Houston, TX, USA
Distribution: Debian
Posts: 569

Rep: Reputation: 31
any C code should compile with a C++ compiler (such as gcc)
gcc is a C compiler
g++ is a C++ compiler

Oh, and stick with Python. It's immaculate.
Old 01-03-2004, 10:26 PM   #6
Registered: Jul 2003
Location: Toronto, Canada
Distribution: Gentoo
Posts: 720

Rep: Reputation: 30
Try lisp
Old 01-04-2004, 04:07 AM   #7
LQ Newbie
Registered: Dec 2003
Posts: 13

Rep: Reputation: 0
One of the interesting differences between the unix and the Windows world
is that unix users seem to be open to many more general programming
languages than Windows users. I think that under Windows, it's mostly
C++, Visual Basic, and Java, (and Delphi?). (I don't use Windows that
much, so I might be off here.)

First point: programming languages are the battle ground of holy wars.
If you want to stay sane, keep in mind that all the languages in wide use
are in wide use for good reasons, even though they're all flawed.

Java is well supported under Linux. It's a very good language for a lot
of things and for a lot of reasons. It's extremely well documented in files
freely downloadable on the net. It's a very safe language and easy to
debug and maintain. You can pretty quickly get up to speed creating
applications that run under Linux as well as Windows and other
platforms and that do all kinds of nifty things.

The official programming language of the gnu project is C and most gnu
software is written in C. This includes most of the core commands and
software you find in a Linux system. The linux kernel is also written in

C++ is an extension of C that provides object oriented features among
other things. It's a very complicated language -- far more complicated than
C. It provides some features that make it safer (easier to avoid errors)
than C, but introduces plenty of its own pitfalls. C++ is probably more
common than C under Windows, where you have Visual C++, MFC, and
all kinds of fancy component technologies.

On the other hand, C is more popular under Linux than C++. This is even
true of a lot of applications with gui's, as a lot of people just use the bare
bones Gtk gui library, which is written in and designed for C.

Under Windows, the DOS batch language is so impoverished that it's really
a nightmare to work with it. The Linux counterpart are the shell languages
which are usable languages for simple tasks. Bash is the most common shell
among Linux users. As a programming language, Bash is quirky and ugly,
but it's often the easiest way to get some simple
repetitive task done. You can even type a simple bash program in at the
command prompt. For instance,
[robert@lady] for file in *.cc; do mv $file ${}.cpp; done
would change the extension of every file with extension .cc to .cpp

I think of perl as a more powerful counterpart to the shell languages. It's
also quirky, but not as bad as Bash. Some people live and breath for
perl and advocate it for everything. Other people detest perl with a
vengence. However, nobody would deny that, with its very extensive body
of libraries, perl can be a powerful tool for a Linux user.

Python is often mentioned in the same breath as perl and regarded as a
classier cousin to perl. It's less quirky, perhaps more of a general programming
language than perl, with some genuinely interesting language features.

There's also a lot of other simple languages. For instance, tcl is common.
I haven't used it.

I've used scsh as a shell programming language, but it's not widely used. It's
based on a lisp variant called scheme. Scheme is a very nice language, with a
very powerful conceptual foundation, so it's a nice alternative to the quirky,
conceptually murky languages more commonly used. The scsh documentation
could use some improvement.

If you use emacs for editing, you'll want to know some lisp. Unfortunately, Emacs
lisp is not a very good lisp dialect in my opinion.

If you want to be more adventuresome, look at some of the less commonly used
but very interesting languages developed by language researchers. For example,
OCaml, Haskell, Scheme, SML, ... These tend to be supported on both Linux
and Windows, but generally better supported on Linux. These kinds of languages
have a very different feel from the quirky, conceptually murky languages commonly
used by most Linux hackers. If you have a theoretical or mathematical bent, you'll
certainly find them more appealing, or at least interesting.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
languages of linux: which languages can be choosen in suse and red-hat distributions? Klaus Schnorr Linux - Software 3 09-10-2005 03:19 AM
Statistical programming languages Nerox Programming 1 03-17-2005 01:01 PM
What programming languages do you know? ugoff General 24 12-13-2004 07:01 PM
How many programming languages do you know? MikeZila Programming 4 07-25-2004 02:26 PM
Programming languages and Linux healfdeane Linux - Software 1 09-10-2003 10:15 PM > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 11:54 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration