Diving into Javascript

03 Sep 2020

Overview of JavaScript

Never using Javascript before ICS 314, it was nice to learn that my prior Java knowledge would help me learn due to their similarities. freeCodeCamp was also a helpful tool when learning it, although ES6 is still a challenge. Coming off of learning C, and liking the ability to see everything going on, the lack of clarity of data types, functions which can return multiple data types, and most of the shortcuts introduced with ES6, are all quite confusing; particularly the latter as it can be tough to see what’s happening. However, given time, experience, and the perspective of it being used for web applications, it’s at least somewhat understandable why these shortcuts and peculiarities exist: that it could save time and be convenient for smaller web-based applications. Overall though, my first impressions are that it would be far more difficult to read and understand someone else’s code; which perhaps could defeat the purpose of the shortcuts anyways: to save time.

Learning JavaScript through WODs

In ICS 314, we use the concept of athletic software engineering, and do what are called “WODs” (Workout of the day). The idea is to time yourself doing a particular problem, then if you go past a certain time you “DNF” and have to start over, or if you do finish you start over again to try and lower your time. The concept is to do at least one easy problem a day, and to become more efficient. I believe there are pros and cons to this teaching style. The immediate benefit is getting used to typing Javascript, and by proxy getting used to it’s aforementioned peculiarities. It’s also good to have a consistent building of knowledge rather than throwing huge projects every once in a while. However, I do have my qualms about the timing and repeating aspects. Giving a short time limit to a problem, no matter how easy the problems, is a stressful concept. As a programmer, of course speed is beneficial, but everyone has a speed limit, and going past that speed limit can easily cause panic, and panic causes bugs and “stupid mistakes”. I believe the way to get faster at a language (or programming in general) isn’t to force speed, but to simply gain experience and to go at your own speed limit consistently. As for the repeating aspect, I don’t see much benefit to typing the same thing over again. As a programmer our nature is to problem solve, and one of the biggest aspects of being a programmer is fixing bugs, whether it be someone else’s code or your own. When you repeat a problem after getting a “DNF”, in all likelihood you’ll either get stuck on the same bug, or even worse you’ll avoid the bug entirely. I say that’s even worse because if you avoid it you won’t learn anything from it, and you won’t get used to bug fixing: one of the greatest opportinities to learn and gain experience as a programmer and a problem solver. I believe there is good potential for the WOD format, with its easy management and consistent growth, but the added stress and timing needs to be thought upon before I’d call it a good tool in my opinion.

Final thoughts

Javascript is a very different language, but I’m glad to learn it, as that can hopefully make me think in new ways. Overall, I’m excited to see where ICS 314 goes and what new things I can learn about making a finished product.