davidktw
Arch-Supremacy Member
- Joined
- Apr 15, 2010
- Messages
- 13,551
- Reaction score
- 1,302
The most layman answer for you isHow did you learn all these?????
It's not just pure diet that accumulates all the vitamins in your body. Some are acquired from the diet, some from supplements and some are generated within your body.
With the above statement in mind, a lot of what I have shared in the previous posts are accumulated from years of learning computer science and playing with multiple programming languages, from my JC and Uni courses, from even days before I have formal training in CS, and obviously from reading and watching plentiful of technology articles and videos(when there is Internet). Last but not least, books both dead tree format(started before I even started CS in JC) and digital format.
I know a lot about software and hardware interrupts during my early days studying computer science in JC. In just that short years, I have knowledge of BIOS interrupts (H/W) and OS interrupts(S/W). One well known H/W interrupt is your RTC timer interrupt. It is hardware generated and you can easily hook on to it with a interrupt handler written in C. The other very well known S/W interrupt is the DOS INT21h. It exposes a lot of system functions, which you can read up from http://spike.scu.edu.au/~barry/interrupts.html
I understand even more in-depth about the above subjects studying Computer Architecture, Assembly languages, and OS design and Compiler designs during my Uni days. These courses will inject with you a lot of concepts on how systems ticks, how various layer of programming languages comes into play and how programming languages are designed.
There is really no magic with polymorphism or virtual functions or all those various scoping techniques like lexical, dynamic, static, closures, anonymous. All these concepts are conjure up based on language design principles. If you understand how a simple function is invoked in C, you will have much deeper understanding into all these. I won't go into details, but suffice to say, different programming languages have different approach to how control is passed to a function. But a lot follows the C convention (for obvious reason). There are also those that does it differently. Very much like between little endian and big endian in architectures. In C, arguments are first pushed in the stack, before the data registers and instruction registers are set to the entry of the function.
Once you have a strong foundation in all these, you will find various programming language constructs are based on the very same foundational principles of playing around with all these architecture components. In some very old posts in this forum, I have always told a couple of fellas that Java has pointers, but they don't get it. They thought just because Java call it references means it is not pointers. On the contrary, references in C++ is indeed not pointers. They are design as aliases. But still all these are nothing but manipulation of numbers(information) with a set of semantics.
Java:
Integer n = new Integer(10);
is the same as
C++:
int *n = new int(10);
and it is not the same as
C++:
int n(10);
Once you get one or a few of them, you can easily apply the understanding across numerous other technological concepts. That is why I always advocate learning Computer Science, not Programming.
Believe it or not, I didn't get started with Python to know about generators and coroutines. I already knew about these constructs from other programming languages. It just happen that Python is so popular that everyone seems to talk about it like dessert after the main course, so why not just discuss starting from something some thinks they already knew.
I hope things I have shared open up people minds. Too often I have observed very close minds. Minds that follow rules which doesn't understand why the rules exists and how to break out the rules. The choice of breaking out of rules comes with consequences and one will need to measure if the consequences are worthy for the rules to be broken. Only when you have choices that you can choose. With an open mind, you will be capable of making informed choices.
I have also from time to time read some that thinks FE is some feat which doesn't require CS knowledge. This is a good chance to share the following video
CSS Paintlet(https://developers.google.com/web/updates/2018/01/paintapi) is FE developers scope of work, just that are you game enough to use it ? In this procedural texture example, it requires the implementor to know about Pseudo Random Numbers Generators (PRNG). Is this therefore a BE engineer work ? Apparently this doesn't seems so right ? So is CS important for both FE and BE software engineers ? Why is there even such a segregation in the first place ? The tech evangelist talk about mulberry32, but I believe a simple LCG(https://en.wikipedia.org/wiki/Linear_congruential_generator) will work too. It just need to look random, not securely random.
Have fun
Last edited:
