I notice a lot of code being written in C these days. I've been learning C++ on my own for a couple of months, but it surprises me that C is thrown around a lot in this board.
Why is that? Should I quit learning C++ and migrate to C, or is it just a matter of preference for homosexuals like you.
Name:
!iN.MY.aRMs2010-02-10 22:18
use FORTRAN77 ever
Name:
Anonymous2010-02-10 23:17
>>1
It's because C is the language Unix was built on. Everything even remotely Unix-derived inherited C, so it has developed quite a cult. On top of that, it fills its niche (portable assembler) fairly well and has no real competitors, so pretty much every platform has a C compiler. It may not be suitable for most applications, but because of all the above, people try to use it anyway.
Should I quit learning C++
Suss, yes. The answer to this question is always “yes”.
Name:
Anonymous2010-02-10 23:42
C++ is pretty shitty. If you're going to learn OO you should learn a language that isn't riddled with too many features and way overly complex, due to implementation by a fucking committee. This is honestly and objectively the consensus of most of the programming world these days. C++ is dead, except for games. Often when C++ is used many restrictions are put on how you're allowed use it because there are too many features in the language. There are literally 50 completely equivalent ways to write fib(x). You'd think that's a good thing but it makes your code totally unreadable to 70% of the other coders out there. It's just a terrible, terrible, language.
C is just assembly that wants to be it's own language. Generally that's okay though.
C as assembly is a good description. It's why it's considered so adequate for system programming.
C++ is a pretty evil abomination. I still use it, but most of the time am working in "C mode", e.g. the Win32 API.
Focusing on C alone seems to me to be the best idea for a programmer new to the ways of memory management, pointers vs. array types, etc. -- I imagine C++ just adds a useless cloud of brain is full of fuck. At least skip learning how to overload operators.
Name:
Anonymous2010-02-11 0:15
What would be the best one to learn that isn't C or C++?
>>6
You should learn C and the platform's assembly language. Doing this right would give you a solid understanding of the hardware in both a concrete and abstract manner. After that you should read SICP and go the ways of >>7 or >>8. I went to way of >>7 myself, but CL is a complex language which makes some people dislike it and just go the Scheme way. I've chosen to stay with it due to portable macros(and separate function and variable namespaces which makes low-level macros reliable(of course with gensyms too)), ability to use declarations, rather rich and flexible standard library (I love those lambda lists and how well thought some of the standard library functions can be - they tend to perform a lot of the things I commonly want, though not everyone feels the same about it), compilation model and overall dynamic nature of implementations (recompile/replace any code you want, only declare types when needed, ...). However, I cannot recomment a newbie learn CL without prior experience with at least a few languages(some people did learn it first), so he should probably read SICP first
Name:
!iN.MY.aRMs2010-02-11 5:47
"computer scientist" who read SICP and love lisp is gomosexuaist
unuseble to help me calculate nuclear reaction
Name:
Anonymous2010-02-11 6:10
"computer scientist" who read SICP
>"russian peasant" who read SICP
Name:
!iN.MY.aRMs2010-02-11 7:13
>>13
only gomosexual capitalistic "computer scientist" read SICP
in russia SICP is baned as transtedeintal suicidal literature
if you're going to program in C, do it right; use C, not sepples faggotry.
if you're going to do OOP, do it right; use Java.
if you're going to do programming to impress your smarmy, elitist, esoteric language hipster friends, do it right; use Lisp or any functional programming language.
if you're going to write quick and dirty one liners, do it right; use perl.
blah blah blah, etc etc etc.
>>16
its gomosexual unuseble "computer scientist"
dont listen him
Name:
Anonymous2010-02-11 14:03
>>1
Yes. It is a matter of preference. Both C and C++ are Turing Complete. C++ also happens to be Touring Complete with the ducks provided by MFC, however this is not considered to be noteworthy because it is non-portable. The same effect can be had by abusing C macros anyway.
>>24
At present 8000 dealers from 600 cities cooperate with 1C. About 3200 teams constitute the 1C:Franchising partner network,which is a main channel of value-adding for 1C products. Service-partners provide regular information and technological support for 1C software customers. The network of authorized training centers is also operating. There are 280 1C:Multimedia software retail shops of the franchising chain, specialized in sales of home products.
1C is the official distributor of such world-famous vendors as Microsoft, Novell, Borland, Symantec, ABBYY, Kaspersky Lab, ProMT, Eset Software and over 100 other software vendors. 1C offers more than 10 000 titles of software for office and home use.
need more information? folou: http://1c.ru/eng/title.htm http://www.v8.1c.ru/eng/
>>28
A lot of them are poorly implemented, as instead of being designed as a whole language they took C and added a bunch of random features the developers liked.
Just about every platform you'd care to program on runs C. Every language anyone would care to use can interface with C.
Never write a library in anything other than C, unless it's totally niche and you don't want anyone to use it. Especially never make a library in C++.
Name:
Anonymous2010-02-12 12:17
>>32 Especially never make a library in C++.
This.
>>32
I see nothing wrong with writing libraries in other languages, especially if you're only making them for yourself and other users of that language (not talking about SEPPLES here). I for one am very glad to be able to find all kinds of obscure Common Lisp libraries for just about everything I need, and interoprating with them is less effort for me than building a C library (which usually can be very easy or moderately hard depending on dependencies, however here all I have to do is make sure I place the libs within the right path, and just instruct ASDF to load the one I need, and it will recursively compile/build and load everything).
Name:
Anonymous2010-02-12 15:38
>>34
Unless, of course, that particular library doesn't work with the CL implementation you're using in which case it's useless.
Accessing a C library using UFFI is much less of a hassle.
>>35
Most implementations are easily obtainable. I'm mostly using SBCL and CCL, with ocasional ECL and CLISP usage. Have 69 ASDF systems installed, and they work fine (albeit some people have mentioned there can be quite annoying version incompatibilies between libraries, I have yet to encounter this, but that's probably because I grabbed the latest version of them that I could find). Accessing C libraries isn't hard, but I have much more pleasant time debugging pure lisp code than mixed C and Lisp code in the long run.