Good morning (?)!

If you enjoy reading this newsletter consider helping us by spreading the word via Twitter or simply forwarding to a friend.

Now on with the articles!

Articles

(Nov 26) #javascript

In JavaScript you can "unpack" an objet or an array into multiple variables like so let [firstName, lastName] = ["Bobby", "DropTables"] //firstName = "Bobby", lastName = "DropTables" . This special syntax is called Destructuring assigment and can be useful in many scenarios. One such scenario is when designing APIs, like in Chris' case where we want to create a function that takes multiple parameters of the same type but we want to make it clear from the caller side where each one will be used.







(Nov 27) #ruby

Since 1.9 Ruby has Fibers, a lightweight concurrency construct that allows one to suspend and resume execution of blocks. In this article Julik Tarkhanov goes in depth about the differences between Fibers and enumerators as well as generally constructing control flows.







(Nov 26) #unicode

James Bennett understandably is not a fan of the recent trend of "falsehoods programmers believe" articles and decided to educate us with things we SHOULD know about in the form of an in-depth article as opposed to a simple listicle. In this first post of the series he talks about case; the upper and lower variety. In it we learn a few pitfalls Unicode has that we should be aware of and some lesser known facts (like that there is more than two cases!).







Programming language of the day: L2."L2 is an attempt to find the smallest most distilled programming language equivalent to C. The goal is to turn as much of C's control structures, statements, literals, data structure constructs, and functions requiring compiler assistance (setjmp, longjmp, assume, ...) into things definable inside L2 (with perhaps a little assembly). The language does not surject to all of C, its most glaring omission being that of a type-system. However, I hope the examples below will convince you that the result is still pretty interesting. And if that is not enough, I recommend that you take a look at the implementation of a self-hosting compiler for L2 that accompanies this project and compare it to the compiler for bootstrapping it written in C."



And that's it for today! Discuss this issue at our subreddit r/morningcupofcoding.

Did you like what you read? Let us know by clicking one of the links below.

Liked - Disliked

I hope you enjoyed reading the latest issue of Morning Cup of Coding. If you did, consider supporting it by becoming a patron (Patreon), buying me a coffee (PayPal), donating anonymously (coinbase), or purchasing an MCC mug (RedBubble); it helps me keep this going.

Cheers,

Pek