What to do after Python?

Erik Max Francis max at alcyone.com
Mon Feb 19 00:49:51 CET 2001

Kenneth Loafman wrote:

> Please also teach the C Standard Library along with C++.  I've seen
> some
> very poor examples of "reinventing the wheel" happen because the
> student
> did not even know the basics of the C Standard Library and its
> interaction with the basic elements of C/C++.  Consider one case I
> found
> where the goal was to remove the last character of a line.  Instead of
> using something like:
>    if (strlen(s)) s[strlen(s)-1] = 0

If one is actually writing Standard C++, one doesn't need the str... C
functions, since one won't be using NUL-terminated C strings, but rather

> the (7-year C++ veteran) wrote several lines of code that:
>    reversed the string
>    trimmed the first char
>    re-reversed the string

If he actually thought that was a viable solution, he wasn't a veteran
of _anything_.

 Erik Max Francis / max at alcyone.com / http://www.alcyone.com/max/
 __ San Jose, CA, US / 37 20 N 121 53 W / ICQ16063900 / &tSftDotIotE
/  \ A man that studieth revenge keeps his own wounds green.
\__/ Francis Bacon
    Product's Quake III Arena Tips / http://www.bosskey.net/
 Tips and tricks from the absolute beginner to the Arena Master.

More information about the Python-list mailing list