Is it really that good?
Is it really that good?
Other urls found in this thread:
harmful.cat-v.org
open-std.org
twitter.com
It's an elegant tool from a more civilized age. Nowadays, very few have the mental discipline and dexterity required to wield it without harming themselves.
C is for cucks tho
Plenty of shit could have been done without bringing in OOP cancer.
Operator and function overloading with standard mangling scheme, strong typing, type inference, nested functions, switch ranges, stopping support for ancient archs and instead defining behaviour for machines with linear memory model and POT types and 2's complement, more standard macros like __LITTLE_ENDIAN__ and __BIG_ENDIAN__, standardized struct packing, portable lib for sockets and so much more could be better, but it's still a language with the least shit in it.
how so?
>very few have the mental discipline and dexterity required to wield it
Ah, the joy of getting segfault!
>not ++
>not #
nope. it's like using the shittiest most primitive tool instead of a better modern tool so you can feel superior to other people
>t. uneducated nigger
>++
>#
nope. it's like using the shittiest most primitive tool instead of a better modern tool like Rust or Go or D so you can feel superior to other people.
>rust
>go
>D
literally what? try gerting a job coding in those memes neckbeard
But Go has jobs.
>C
>elegant
Why aren't nested functions a thing in C anyway?
>Is it really that good?
It was one of the best back in its day. Lean, direct, powerful and dangerous. Writing exemplary code in C was like taming a wild horse, and many hackers were excited by that.
Not anymore though. This language is old and it shows. C++ has superseded it, providing the same speed with a small increase in memory consumption. The only reasons people still use it are convenience, nostalgia and old code maintenance.
C is a disservice to intelligent programmers. It has almost 0 features that a modern and intelligent programmer uses to be productive. Since C is such a timesink, it's popularity is falling more than any other languages in the market.
C is dying and it should die ASAP. C programmers are actually retards in general. C is a small language to grasp, exactly the kind of shit that makes things retard friendly.
C has no advanced features like C++ does.
But as a newfag you are kinda in the right direction. C is for newbies. Think of it this way:
During ancient times, counting to 10 was a big deal and a person who could count to 10 was considered to be "wise".
Fast forward a few century counting to 10 is so trivial we teach this to toddlers. Now toddlers appreciate the vast "knowledge" of counting to 10 while matured brains are busy with modern technologies.
C is from stone age and the people who still preach it is like overgrown toddlers that can't learn advanced things. C is for lesser programmers.
C doesn't have delegates
C doesn't have resizable arrays
C doesn't have strings
C doesn't have string concatenation
C doesn't have namespaces
C doesn't have exception handling
C doesn't have closures in the standard
C doesn't have unit tests
C doesn't have Function overloading
C doesn't have memory safety of any kind
C doesn't prevent memory exploits and has no bounds and runtime checks
C doesn't support dynamic method loading/creating
C doesn't even have generics and templates
C doesn't have meta programming
C doesn't have mixins
C doesn't have higher order functions
C doesn't have contract programming
C doesn't have inner classes
C doesn't have function literals
C doesn't have array slicing
C has a very limited support for implicit parallelism
C doesn't even have string switches
C is a cancer that plagues the modern software industry.
What should be my first language? C++?
You sure spelled JavaScript wrong
>C doesn't have delegates
function pointers
>C doesn't have resizable arrays
realloc
>C doesn't have strings
char*
>C doesn't have string concatenation
strcat
>C doesn't have array slicing
Offset your pointer
C++ is a complicated language, don't learn it until you're familiar with both C and Java
This, kids, is what over-exaggeration looks like. Don't be this guy. You don't need to stroke your ego by insulting other people.
Nonononono, if they're to learn C++ they should skip C entirely, no reason to learn it. Learning C first will only teach them bad C++ habits.
Poo
Learning C++ without learning C will leave you hopelessly unaware of what your C++ abstractions are doing under the hood, which is terrible since they're so leaky.
Keep in mind that I'm not saying you should write C++ the same way as you write C. I'm just saying you should be aware of what's going on. The style of C++ you write should be tailored to the kind of software you're writing.
>Learning C first will only teach them bad C++ habits.
learning C teaches you how a computer werks, nigger
Show me one person that has learned C++ as a first programming language.
Show me one beginner(As in, a first programming language) C++ book that isnt utter shit.
You cant, you delusional and completely oblivious to the real world faggot.
>learning C teaches you how a computer werks
no, it doesn't
>no, it doesn't
LOL IT DOES THOUGH :D
like what ?
> delegates
Are a perfect example of solving the WRONG FUCKING PROBLEM. Lambdas solve the problem. They solve the problem better, even.
It's like properties. Are properties good or bad? They're neither. They're just syntactic sugar. Sugar over what? Sugar over writing boring bullshit code. And while it's nice to not having to write that specific type of bullshit code, there's still other bullshit that needs to be written.
What's the proper solution then? The proper solution is to tell the compiler to write the fucking code. It should know what the bullshit code should look like.
> But user you handsome man-beast, compilers cannot be expected to know all the standard patterns.
Then there should be a way to teach a compiler such things. Common Lisp has compiler macros. Anytime you catch yourself writing bullshit code in CL, you can tell the compiler how to do it instead. The entire object system in CL is based on the compiler doing the boring stuff for you. A bean equivalent in Common Lisp is just a list of fields, with the equivalent of annotations that say what access you will allow to them, etc. It's amazing.
What really hurts my soul though is that people don't want to play around with languages like this. If they did, they would come to a painful realization. A lot of language features are just syntactic sugar, and this syntactic sugar is limited, and you can't make your own.
C on the other hand doesn't have syntactic sugar. It doesn't even have imports, the preprocessor does that for C. C is in other words, what modern languages start to resemble as you peel away their abstractions.
Lisp is what you get when you start peeling away the language itself and lay the end product bare for your meddling. They're very clean languages for those reasons.
Not really, it teaches you how procedural programming works. Assembly and OS programming teach you how the computer works.
>Show me one person that has learned C++ as a first programming language.
Me
bits n stuff xD
Tell me one thing C can do that C# can't do better/faster/automatically.
Good.
Now tell me why one should learn C.
retard, it even abstracts byteorder
>back in the day people didn't harm themselves
>Aleph1 never published his phrack article because stack overflows weren't a dime a dozen in 1996
good joke, son
harmful.cat-v.org
Linus Thorvald explaining why C is for the best.
C is a good language, but is far from elegant. Any sufficiently advanced C program that isn't raw spaghetti code will invariably develop crappy ad hoc features already found in other languages, and contrary to what the kind of autist you'll find on suckless seems to think, you can't fix this by refusing to perform complex tasks entirely. Object oriented tards may have failed to address this, but that doesn't mean the problem doesn't exist at all.
Then again I get half mast when I see Lisp macros so what do I know.
"Bad programmers worry about the code. Good programmers worry about data structures and their relationships."
Linus Thorvald
That was my point. We really would be writing everything in C if only clarity mattered.
You should still consider it if you plan on making a small unixy tool though. Go is so aggravating to use that it's
>realloc
Managing memory by yourself, because the language is so shit, doesn't count as ability to resize arrays
>char*
string != char*
>strcat
Calling fancy string.h libraries doesn't count, because it's not integral part of language as standard "string" + "string" concatenation in other languages is.
just use a proper language that has decent form of linking to C libraries and you will benefit from both words, cleaner syntax from a modern language and ancient well tested and robust libraries. Dont link C libraries with Go do.
You mean the book or the language or even the whole ecosystem?
Nevermind, the answer is no in any case.
Why aren't sane metaprogramming facilities?
this
There is nothing elegant about a programming language where textual replacement are the only means of metaprogramming.
>i-it doesn't count!
>Managing memory by yourself, because the language is so shit, doesn't count as ability to resize arrays
Yes, it does. And automatic memory management is not inherent to high level languages. Do you think it magically manages itself?
If you hate memory management so damn much you can use Boehm GC anyway.
>string != char*
A string that isn't some nebulously defined "object" is still a string.
>Calling fancy string.h libraries doesn't count, because it's not integral part of language as standard "string" + "string" concatenation in other languages is.
It's part of the standard library, you idiot.
additionally:
>needing to create a copy your data
>If you hate memory management so damn much you can use Boehm GC anyway.
Not him, but Boehm GC is defective. Which is why the only acceptable reason to use it is language prototyping.
yes /thread
>memory management
Not hating it, just calling it obnoxious for such a simple task.
>string
It's obviously more beautiful to have array of chars, rather than well defined object with useful properties, proper bounds and "nebulous" methods, which are actually use friendly, not like f.e. strtok
>std
Then you could argue, that you don't anything at all in language itself and handle all by libraries, which is pretty stupid design.
>Then you could argue, that you don't anything at all in language itself and handle all by libraries, which is pretty stupid design.
I disagree. Powerful libraries just demonstrate that your language is expressive enough to have robust abstraction-building mechanisms.
The standard library is literally described in the C standard. It take up a major chunk of the document. You're wrong on this point, accept it and move on.
AungularJS is in every way superior, 99.4% ms latency, 134.69% disk space, 400 compiles per compilation.
C Is literally a meme made by some people who didn't know their ass from their elbow
Disclaimer: I am hired by Google.
everything
c# is a managed language
it's magnitudes slower
How do I git gud enough at programming to understand your post user
What's the difference between delegates and lambdas anyway?
At what point should you choose C++ over C for Linux apps?
depends if you're programming hardware/networks
When a toolkit/API forces you to. Even then you should code C++ as you would C as much as possible, because C++'s OO (and OO in general) is fucking stupid as hell.
Neither. IIRC, C++ is better for both.
Thanks.
>Is it really that good?
It's not good but it's the best we currently have. SAD.
Of course I don't disprove that.
My point is that something like string operations should be integral part of a languge
why
What about the book, is it really that good?
no, it can as well be a library.