Function naming is hard (even PHP-FIG gets it wrong)

Craft, Programming, Uncategorized

There’s a famous saying that two of the hardest problems in computer science are cache invalidation and naming things. When it comes to defining standards, there’s no cache involved, but there is a lot of naming of things. It should come as no surprise, but I recently was shocked to see that the folks who create […]

Continue Reading

Simple, lightweight Rust tutorials

Uncategorized

So I finally decided to write some tutorials. For Rust. I’ve kept myself from writing any tutorials before, but this time I made an exception. Here’s why. Be advised, though. There’s nothing special in these tutorials. I write them as I learn Rust from the only excellent book online, and the content and structure of […]

Continue Reading

Learning Rust – One tutorial at a time

Uncategorized

I never wrote any programming tutorial before. That’s a paradox for those who know me, because I absolutely love to learn and teach. Why not a tutorial till now, then? To put it briefly, I haven’t been sufficiently excited about a programming language before. Sure, there’s Python, Go, Elixir, Kotlin, and many other elegantly designed […]

Continue Reading

Enjoy Those Lights!

Showcase, Uncategorized

Today I have taken an important step towards unchaining the designer in me. And it has to do with the choice of color scheme for coding. Now, most developers will agree that color-coding is extremely important in programming (it allows us to quickly discern parts of the code we want, and improves focus and readability) […]

Continue Reading

How many Controllers should you have? [Laravel]


Frameworks, Laravel, PHP

Controllers are the life and blood of a Laravel application. It’s impossible to imagine a framework without them (well, it is, but technically something has to receive the route action, and whether it’s a class or function, it becomes a controller, so to speak). In the last 3-4 years of my development experience, I went […]

December 16, 2017

The curious relationship between Laravel and Node.js


Laravel, PHP

Even a cursory survey of skills (try LinkedIn) will tell you that a huge percentage of Laravel developers end up learning Node.js. The skills list goes something like this: “LAMP, Laravel, Ionic, Node, Full Stack Developer”. And it’s not just beginners bragging about their skill-set, mind you; I’ve met serious architects who passionately love Laravel and […]

December 14, 2017

Rust Tutorial – Part 6 – Functions


Rust, Tutorials

Functions in Rust are much like functions in conventional languages – simple entities that accept an input and produce an output (but not always). Here’s a very simple example of a function in Rust: fn main() { simple_function(32); } fn simple_function(x: i8) { println!(“The value received was {}”, x); } So, we see that functions […]

December 8, 2017

Rust Tutorial – Part 5 – Tuples and more


Rust, Tutorials

Tuples are perhaps the most fun data type we’ll encounter in Rust. They are convenience and elegance rolled into one, as we’ll soon see. The idea behind tuples is to let you group together items of different types. If you’re coming from a language like PHP, you might like to think of associative arrays; the […]

December 6, 2017

Rust Tutorial – Part 4 – Primitive Data Types


Rust, Tutorials

[This post is part of the series on Rust programming tutorials that I’m writing for enjoyment. All the tutorial links are here.] Let’s take it step by step. I assume you know what data types are (if not, please run away; Rust should not be your first programming language – it’s far too interesting and powerful […]

December 5, 2017

Rust Tutorial – Part 3 – Constants


Rust, Tutorials

[This post is part of the series on Rust programming tutorials that I’m writing for enjoyment. All the tutorial links are here.] Rust allows you to write constants; that is, things that aren’t going to change at all. If you’ve read the previous tutorial on variables, you might be thinking: why constants when all variables […]

December 4, 2017

Rust Tutorial – Part 2 – Variables


Rust, Tutorials

[This post is part of the series on Rust programming tutorials that I’m writing for enjoyment. All the tutorial links are here.] Variables . . . things that hold other things. What other things? These other things vary from language to language, and range from values to references to direct memory addresses (the last one […]

December 3, 2017

Rust Tutorial – Part 1 – Hello World


Rust, Tutorials

[This post is part of the series on Rust programming tutorials that I’m writing for enjoyment. All the tutorial links are here.] Every programming language must begin with printing “Hello, world!” to the screen. It’s not mandatory, but it’s a tradition honored by great programmers through the ages; and who am I to break that […]

November 29, 2017

How I organize code when I’m learning


Craft

So here’s what this looks like from the rooftop: You’ll see lots and lots of directories there, which reflects my impulsive nature. There’s stuff like NodeJS there (which I left half-way), zeromq (which I never even got started on), Go (which I did finish, by the way!), and more. But that’s not all. The real […]

November 29, 2017

Simple, lightweight Rust tutorials


Uncategorized

So I finally decided to write some tutorials. For Rust. I’ve kept myself from writing any tutorials before, but this time I made an exception. Here’s why. Be advised, though. There’s nothing special in these tutorials. I write them as I learn Rust from the only excellent book online, and the content and structure of […]

November 28, 2017