4 ms·
I think a large problem with this is that people unreasonably idealize the features of ALGOL 60 and many other "Perfect Systems Languages" The issue is that th
by gravypod 10y ago
I think a large problem with this is that people unreasonably idealize the features of ALGOL 60 and many other "Perfect Systems Languages"
The issue is that there are not any major open source projects to examine that use these languages to see how they actually work in the wild. For example, writing a Java codebase with nothing other then the standard library you can do some very nice design patterns. You can come up with some very clean and concise code and everything can be perfect. Then, when you go to integrate with someone else's code (see Spring) you notice that everything becomes a mess since they are using some crazy things that make it very difficult to integrate with it.
Due to this it's impossible to say how well another language would behave in the wild since I don't think anyone can predict how well the language will be used to it's extent.
That being said, I think C succeeded because it was SIMPLE. Not only for the compiler, but I can teach pretty much anyone how to understand C in most likely a few days to a week. It's very simple and very little you need to know to understand how to start writing your programs.
On the other hand, ALGOL is MASSIVE. There are 106 reserved identifiers in the language according to wikipedia and I don't think I could ever remember what every one of them did.
Currently C has about 32 key words and I can tell you in full detail what every one of them means except union as I don't work much with C.
This is good for the beginning programmer since it shortens the time they need to hit the books and helps them jump strait into writing.
Something that's good for the advanced programmer, in my opinion, is the use of braces and not words.
I know this is kind of controversial but I do honestly think that a code should be easily segmented by the eye not readable.
Begin and End only help so much and by so much I mean not at all. Words should not be syntax in my opinion. Seeing { } is less to look at and understand then seing Begin and End.
This sample phenomenon can be looked at from the recent Linux 1000 patches debacle.
Linus said he didn't want to replace unix file permission numbers with the symbolic values. Why? Because it's much much faster for someone to see the numbers and know what's going on then to have to read a bunch of text. It's much quicker in parsing.
That's where the breakdown comes in these discussions. People will throw "You've never used these, how do you know yours is faster."
While that's true that doesn't really present a good argument for changing everything.
I also hate needing to type := for assignment. It makes no sense. Fixing the beginner issue of missing the second equal sign in an if statement has a much simpler fix. Use some kind of IDE/Editor with a linter. You'll not have this problem.
- dalke 10y ago> "Currently C has about 32 key words" That was in C89. C99 and C11 added 5 and 7 more, respectively, bringing the count to 44 in modern C.
- gravypod 10y agoI stand corrected then, make the number 44.
- AnimalMuppet 10y ago> I can teach pretty much anyone how to understand C in most likely a few days to a week. I learned C from reading K&R over a Thanksgiving weekend, without even a compiler to try it out on. The only thing that confused me was the explanation of argc and argv.
- deleted 10y ago[deleted]
- nickpsecurity 10y agoI learned an industrial BASIC in a few hours if you add it all up. Learning how to use it reliably took weeks with safety mostly coming by default. Learning that for large stuff took several months where I learned programming practice. How long do these milestones take for average C developer with what productivity? Note that my Pentium 3 at 400MHz could compile the compiler in a second or two. Fast iterations. :) Learning C was a different experience entirely. The mental work involved was huge with the level I worked at for any job being micro-managing the machine. It's only simple on the surface. The job is much harder than a BASIC, Oberon, or whatever with selective use of unsafe features.
- AnimalMuppet 10y agoI said that I understood the language after reading K&R. The language is simple. Using it safely? Not so simple. I didn't claim that it was. On the other hand, I learned BASIC on a TRS-80. Safe? Not with the POKE command being part of the language.