Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

I'm new to programming: which language?

Name: Anonymous 2010-01-11 23:28

As the title says, I'm new to programming, I've only ever done basic and slightly advanced  Windows DOS language, and I know that is pretty limited in what it can/can't do. I hear that CL/Scheme are the main languages on this board, but I've also heard that they're old and obsolete, someone even told me that Lisp can't call external programs, is that true?

A couple people told me Python was a good language to learn, and I know a lot of programs are written in C/C++, and I've heard of some olders ones like COBOL, FORTRAN, Haskell, and a few others.

I've heard of these dynamic and static typing things, and I believe strong and weak typing, can anyone explain the difference? I've been involved in computers for most of my life, and I think it's time to advance my computer skills, and I could think of no better place than 4chan's /prog/, namely because I don't know of any other places, so....

Can /prog/ help me?

Name: Anonymous 2010-01-12 10:35

As the title says, I'm new to programming, I've only ever done basic and slightly advanced  Windows DOS language, and I know that is pretty limited in what it can/can't do.

Windows batch scripting is limited, but it's also touring complete, however you shouldn't use it for real work or you'll tear your hairs out of your head.

I hear that CL/Scheme are the main languages on this board, but I've also heard that they're old and obsolete, someone even told me that Lisp can't call external programs, is that true?

CL and Scheme are not obsolete, at least no more than most other programming languages out there. CL's standard lacks support for multi-threading, FFI and networking, but it's de-facto implemented, so it just works. Other languages like C don't have support for these things either, but as time passed people have standardized these things(like POSIX), or implementations provided support for them(like Win32 API). You can do in them anything you could do in any other language, except they make metaprogramming a lot more easy and fun. Due to runtime library overhead, it's unlikely you'll write device drivers or loadable kernel modules in them (unless your OS is a Lisp OS), but it's possible. As for calling external programs, most implementations provide a `run-program' function, however if it didn't exist, you could just make your own using the FFI.
CL and Scheme are old languages, but why would that matter? C is an old language as well, and people still use it. A language only dies or disappears into irrelevance when something better appears making it unnecesarry. It's very hard, if not impossible to copy Lisp's features without making yet another Lisp. People would just end up reimplementing Lisp clumsily if they didn't know how to do it right(see: XML "languages").

A couple people told me Python was a good language to learn, and I know a lot of programs are written in C/C++,

Python is considered a good newbie language, and it has many libraries, but it's just another scripting language, so it shouldn't be the only thing you'll learn.
C is a glorified portable macro-assembler which can perform register allocation, which means it's almost one of the languages which produce relatively fast code as long as you have a good compiler. C++ is an "OOP" language which tries to stay compatible with C, but it ended up being quite large and having a very tricky syntax and unpredicatable characteristics. It's used in games and other places where they have a lot of complexity to deal with, but also want C's speed. There are other good alternatives to C++, but I don't expect the industry to change their ways anytime soon.

and I've heard of some olders ones like COBOL, FORTRAN, Haskell, and a few others.
COBOL is old, and unless you want to maintain ancient COBOL codebases for cold hard cash, there's no reason to learn it.
FORTRAN is liked by number-crunching people and it's basically a straightforward imperative language. It's not much different from C or Pascal at the core.
Haskell is quite a young language, why do you call it old? It's a statically typed(with type inferrance) purely functional lazy language. It shows very interesting ways to do programming, albeit I don't think it's the most practical language for writing real-world applications, but if you think in types, you should give it a chance.

I've heard of these dynamic and static typing things, and I believe strong and weak typing, can anyone explain the difference? I've been involved in computers for most of my life, and I think it's time to advance my computer skills, and I could think of no better place than 4chan's /prog/, namely because I don't know of any other places, so....

Static typing - types are tied to variables and known at compilation: either your specify the types(like C, C#, Java, ...), or the compiler can infer types from how they are used(Haskell, ML,...). Static typing can sometimes be constraining, but it allows for better speed and ability to be certain of the correctness of typing(unless you go sprinkling casts all over the place or deal with pointer arithimethic like in C, in which case things can be fairly unsafe if done wrongly).
Dynamic typing - variables are usually just names and can hold any type. Values can be typed, but variables are usually not typed. Type errors can manifest at runtime instead of compile time. This allows for much more flexible programming, but you should test your code more rigurously to avoid errors. Some implementations may even provide some type inferrance for dynamicly typed languages to help you weed out some errors and increase performance. Some dynamicly typed languages can be very safe if they have a good condition/error-handling/exception system, but others can be brain-dead when it comes to safety if they just implicitly cast values from one type to another(such as PHP does).

Can /prog/ help me?

Read SICP, K&R, learn some assembly too. Make sure to have implementations of the languages you're learning ready, as this can help greatly.

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List