Quote:(01-06-2017, 08:01 PM)Dr. Keter Wrote: [To see links please register here]
Well, not really first language. Perhaps first official language. I have experience in Python, but I haven't done more than really dabble. I have officially started learning C, and I plan to keep at it until I git gud. I picked C because I want to do a lot of low-level work, and eventually move onto and learn Assembly.
Considering that I don't have to learn the basics of programming in general, such as what a variable is, is there any reason why C wouldn't be a good language to master first?
C was my first language, but I suppose times have changed since then.
C is definitely a solid pick for a first language, but keep in mind that it is very minimal compared to modern languages.
It does not have the facilities of more recent languages, forcing you to (or letting you, depending on perspective) implement most things on your own.
For example, C does not have strings. Instead, you use character arrays and some simple functions provided in string.h.
Another thing is its lack of garbage collection or automatic memory management.
All memory management in C is done manually, meaning you will have to pay attention to how your program handles system resources.
Lastly, all memory safety is up to you to implement. At worst, a C program can be extremely vulnerable to exploitation because of incompetence.
However, if you implement checks for undefined behavior and take proper memory safety precautions, a C program can be quite secure, yet faster than any modern language.
If you choose C, it will not be the easiest pick. You will probably spend more time experimenting with practice programs, memory management, and data manipulation than if you chose a language like Python.
However, if you succeed you will find that you have gained an intimate knowledge of many lower level things that modern languages usually cover up.
So in the end it's a question of whether you want to focus more on lower level hardware/systems programming or application development.