[phawkins at connact.com: Re: python and applications]

Gustavo Niemeyer niemeyer at conectiva.com.br
Mon Jul 23 16:41:09 CEST 2001

Hi Gustavo!

Before starting, I think comparing C and Python at that level is
useless, since these languages have different purposes. Anyway,
let's go...

> I am just a python beginner, but clearly C would cannot do many thing
> in python the same way you cannot do many thing in C!

I don't think so. Using C you are able to do anything you can do
in python. Remember, the main implementation of Python is written in C.
Many tasks will just take longer to be done in C.

> C is simple, and very, very small. Everything you need come form

I wouldn't say that at all.

> libraries. C has no support for IO, garbage collections, dynamic
> memory allocation, etc...... Many thing that C "does" comes from
> external libraries. Being small, and without any kind of special

So does python. What do you think you're doing when you use something
like "import sys" in your program? Yes, many of these libraries
are part of a "standard set", but that doesn't change things. You
have POSIX and other standards on the C side.

> structs gives C some nice features like: small learning curve, code
> are easy to mantain , you can write very fast code in C, easy to

I'm not sure I'm reading this... :-) Com'on.. Python is so valuable
exactly because it has a very small learning curve, and because code
written in Python is so easy to write and maintain.

> program. The most sofistaced feature C provides is loop (while, do
> while, for), the lowest level C feature are pointer. If you master
> pointer and loop in C, you may be concidered a C guru. the problem is

Ouch... What's a feature for you?? If you're talking about the language
constructs, as far as I remember, Guido is always trying to have the
minimum possible set of language constructs in python (no do/while, no
switch, no enum, etc). I don't think this is a bad thing, but I don't
understand your position.

> that C by itself is useless. Writting really useful programms required
> you to master the OS API, or even your hardware.

You can "master" the POSIX standard, just like you'd "master" the
python stdlib.

> that C++ is easier than C - All i do is laughting. Serious IT stuff
> never get project developed in C++.

We have lots of well known projects developed in C++ (qt, apt, etc).

> Python is much more elaborated than C. It supports complex data types
> (from the point of view of a C programmer), and operation on such Data

C has very complex data types, from the point of view of a Python
programmer. As I told, these languages have different purposes and
one has to be careful when making such comparisions.

Gustavo Niemeyer

[ 2AAC 7928 0FBF 0299 5EB5  60E2 2253 B29A 6664 3A0C ]

More information about the Python-list mailing list