By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
428,631 Members | 826 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 428,631 IT Pros & Developers. It's quick & easy.

Absolute noob to Linux programming needs language choice help

P: n/a
Hey guys,

I am absolutely new to Linux programming, with no w######s programming
experience except a small amount of C++ console apps.
Reasonably new to Linux, BSD etc, got good sound networking base of
knowledge and dont have any problem working the command line etc.

I want to learn a language that I can use in my networking duties that
is most likely to be of use to me. I have a few choices I can think of
being:

Python
Perl
C

Any other Langs out there that would be better suited?

I want to be able to use the app's I write in OpenBSD and RH versions
of Linux

What would you reccomend (Unbiased opinion please, I'm after the
functionality I'll love it later :) )

Cheers

Ty

Jun 21 '06 #1
Share this Question
Share on Google+
10 Replies


P: n/a
st************@gmail.com wrote:
Hey guys,

I am absolutely new to Linux programming, with no w######s programming
experience except a small amount of C++ console apps.
Reasonably new to Linux, BSD etc, got good sound networking base of
knowledge and dont have any problem working the command line etc.

I want to learn a language that I can use in my networking duties that
is most likely to be of use to me. I have a few choices I can think of
being:

Python
Perl
C

Any other Langs out there that would be better suited?

I want to be able to use the app's I write in OpenBSD and RH versions
of Linux

What would you reccomend (Unbiased opinion please, I'm after the
functionality I'll love it later :) )

Cheers

Ty


Yes python will be good for this. I'm not so sure C is better suited.
Definitely resist "shell scripting". Several chapters in Mark Lutz's
_Programming Python_ will help with networking (after you have read
through _Learning Python_ or equivalent). NewRiders publishes _Python
Web Programming_ authored by Steve Holden, who visits this list on occasion.

James

--
James Stroud
UCLA-DOE Institute for Genomics and Proteomics
Box 951570
Los Angeles, CA 90095

http://www.jamesstroud.com/
Jun 21 '06 #2

P: n/a
Thanks James,

Good to know resist shell scripting.

Python web programming now theres something I had no Idea you could do
with Python. how interesting :).

Just been to your website, the letters after your name wouldnt fit very
easily on one line would they :)

Cheers

Ty
Yes python will be good for this. I'm not so sure C is better suited.
Definitely resist "shell scripting". Several chapters in Mark Lutz's
_Programming Python_ will help with networking (after you have read
through _Learning Python_ or equivalent). NewRiders publishes _Python
Web Programming_ authored by Steve Holden, who visits this list on occasion.

James

--
James Stroud
UCLA-DOE Institute for Genomics and Proteomics
Box 951570
Los Angeles, CA 90095

http://www.jamesstroud.com/


Jun 21 '06 #3

P: n/a
Thus spoke st************@gmail.com (on 2006-06-21 03:51):
I want to learn a language that I can use in my networking duties that
is most likely to be of use to me. I have a few choices I can think of
being:

Python
Perl
C
C is not really a choice in the perimeter
of Perl and Python.

Perl was created to do "networking duties" in
the Unix environment and had a phenomenal impact,
was (then) also a long time the number #1 scripting
language for web apps ('CGI' was almost synonymously
used w/Perl).

Then came Python, which was (iirc) also intended for
solving problems around "networking duties" by the GvR,
who didn't like the appearance of Perl-Programs (couldn't
stand sigils and braces, I guess;-).

So it's today just a matter of
1) personal taste, what do think is fancier for you,
2) choice of the community you want to be in.

BTW. I don't really think its a "choice"
at all, I'd use each language where it
applies best.
Any other Langs out there that would be better suited?


Never ever ;-)

Regards

Mirco
Jun 22 '06 #4

P: n/a
<st************@gmail.com> wrote:
Hey guys,

I am absolutely new to Linux programming, with no w######s programming
experience except a small amount of C++ console apps.
Reasonably new to Linux, BSD etc, got good sound networking base of
knowledge and dont have any problem working the command line etc.

I want to learn a language that I can use in my networking duties that
is most likely to be of use to me. I have a few choices I can think of
being:

Python
Perl
C

Any other Langs out there that would be better suited?

I want to be able to use the app's I write in OpenBSD and RH versions
of Linux

What would you reccomend (Unbiased opinion please, I'm after the
functionality I'll love it later :) )


C is extremely low-level -- you'll want to know it well if you ever need
to program something inside the kernel (or study kernel sources to
understand some detail or anomaly), but for general programming it's a
lot of unwarranted effort.

Python, Perl, and a third language you have not mentioned, Ruby, are
very high level, and each is suitable for just about the same range of
programming (almost any programming, except very low-level;-). The
choice between the three cannot really be based on language level or
power because those aspects essentially coincide; rather, you should
choose based on your tastes, and practical considerations such as the
availability of libraries and other tools (which tends to be excellent
for all three languages, so it's unlikely to guide your choice all that
much). If you want to make sure you have no regrets later, a minimal
amount of study of all three is warranted before you pick one to get
deeper into, IMHO.

Me, I knew the Perl of the time very well when I met Python, and I've
studied Ruby later -- Python definitely meets _my_ needs optimally; but
other people, with very different tastes, could well choose differently!
Alex
Jun 23 '06 #5

P: n/a
On 2006-06-21, st************@gmail.com <st************@gmail.com> wrote:
Hey guys,

I am absolutely new to Linux programming, with no w######s programming
experience except a small amount of C++ console apps.
Reasonably new to Linux, BSD etc, got good sound networking base of
knowledge and dont have any problem working the command line etc.

I want to learn a language that I can use in my networking duties that
is most likely to be of use to me. I have a few choices I can think of
being:

Python
Perl
C

Any other Langs out there that would be better suited?

I want to be able to use the app's I write in OpenBSD and RH versions
of Linux

What would you reccomend (Unbiased opinion please, I'm after the
functionality I'll love it later :) )


My favourite's Python, but Tcl is definitely worth a look. It's been
around a bit longer than Python (so more time for every conceivable
problem to have been met by someone and fixed), and I'm not an expert
but I think it's particularly good for things like sockets-- they're
just sort of built in and are very easy to work with.
Jun 24 '06 #6

P: n/a
In article <1h*************************@mac.com>,
Alex Martelli <al***@mac.com> wrote:
<st************@gmail.com> wrote:
Hey guys,

I am absolutely new to Linux programming, with no w######s programming
experience except a small amount of C++ console apps.
Reasonably new to Linux, BSD etc, got good sound networking base of
knowledge and dont have any problem working the command line etc.

I want to learn a language that I can use in my networking duties that
is most likely to be of use to me. I have a few choices I can think of
being:

Jun 25 '06 #7

P: n/a
In article <sl*********************@bowser.marioworld>,
Ben C <sp******@spam.eggs> wrote:
Jun 25 '06 #8

P: n/a
st************@gmail.com wrote:
Hey guys,

I am absolutely new to Linux programming, with no w######s programming
experience except a small amount of C++ console apps.
Reasonably new to Linux, BSD etc, got good sound networking base of
knowledge and dont have any problem working the command line etc.

I want to learn a language that I can use in my networking duties that
is most likely to be of use to me. I have a few choices I can think of
being:

Python
Perl
C

Any other Langs out there that would be better suited?

I want to be able to use the app's I write in OpenBSD and RH versions
of Linux

What would you reccomend (Unbiased opinion please, I'm after the
functionality I'll love it later :) )


I'm known as a Perl hator, but I'll try to be as unbiased as I can.
I'm limiting myself to the three you mentioned.

C is a very simple (meaning "straightforward", not "easy to learn")
language. Almost everything in C is reduced to basic building blocks
that are quite close to how the CPU itself runs. For example, there's
no such thing as a "list" or even a "string" in C; instead, what you
have are pointers, arrays, and a small number of built-in types (and a
small standard library that provides more complex things like strings).
This makes C an excellent language for programming hardware and
low-level stuff like that. However, it's really not optimal for
application programming--it forces you to worry about stuff like
freeing memory and buffer overflows.

I was frustrated with C because I mostly do application stuff, so one
day I sat down to learn Perl. I was amazed at the leap in
productivity--I was able to write an email autoresponder the very same
day I began the tutorial (granted, I was an expert programmer at the
time, but still). Perl freed me from having to worry about stuff like
memory management, and it provided useful things like growable arrays
and dictionaries. However, unlike C, Perl is not simple. Perl is
complicated, ad hoc, and inconsistent. It never really fit inside my
head--I was always afraid there was something going on, some obscure
rule or behavior was lurking. In addition (and here the Perl hator in
me comes out), it's poorly designed as a language: it often makes you
do extra work to do things the better way (for example, local variables
have to be declared, but not globals).

So we have C, which is simple and straightforward but too low-level to
be efficicient at application programming. We have Perl, which is
high-level enough for application programming, but is complicated and
inconsistent.

Then we have Python, which is both simple and high-level.

So, yeah, I like Python best of those three. For someone new to
programming, I definitely recommend learning Python first, unless you
intend to be a expert or professional programmer or to do low-level
stuff, in which case I'd say start with C. Definitely don't start
learning with Perl. It might be the best choice for some people (in
some universes), but it encourages bad programming habits, so I don't
recommend it for newbies. Learning to program in Perl is like learning
to do stand-up comedy by laughing at your own jokes.

For someone looking for looking to learn preferrably only one language,
I'd say Python, without knowing more about your intended problem
domain.
Carl Banks

Jun 25 '06 #9

P: n/a
cl****@lairds.us (Cameron Laird) wrote:

Tcl's maturity advantage is tiny--*maybe* two years. Both began at
the end of the '80s. There've been close to two decades since to
obscure any initial leads.


The difference is more significant than that. Tcl started in 1987, but
Python's history doesn't begin until the early 1990s, unless you're
counting ABC as well.
--
- Tim Roberts, ti**@probo.com
Providenza & Boekelheide, Inc.
Jun 26 '06 #10

P: n/a
In article <rj********************************@4ax.com>,
Tim Roberts <ti**@probo.com> wrote:
cl****@lairds.us (Cameron Laird) wrote:

Tcl's maturity advantage is tiny--*maybe* two years. Both began at
the end of the '80s. There've been close to two decades since to
obscure any initial leads.


The difference is more significant than that. Tcl started in 1987, but
Python's history doesn't begin until the early 1990s, unless you're
counting ABC as well.

Jun 26 '06 #11

This discussion thread is closed

Replies have been disabled for this discussion.