Improve your developer skills with Codewars

Some weeks ago in Mikamai we started using codewars, a website that aims to improve your programming skills via gamification with code challenges.
Since I’m a junior developer willing to improve my Ruby knowledge I have used it a lot lately, so let’s see how it works.

After signing up and completing a simple code problem, you can start browsing some kata and boost your programming skills.

Why kata? Codewars has this oriental, martial arts flavor so you’ll find words like kata and train for quizzes, kyu and dan to classify user rankings.

Personally I’m really enjoying the site and the learning process.
The number of Ruby katas is huge, and I find expecially nice the chance to see other users solutions after you complete a kata, so you can see super-compact solutions such as:

def anagrams(word, words) { |w| w.chars.sort == word.chars.sort }

or regular expressions usage to solve a wide range of problems:

def pig_it text
  text.gsub(/(w)(w+)*/, '21ay')

and you can write your own tests while you’re training a kata.

You can choose among many programming languages (I’m looking forward to see Elixir or Rust in the future).

Initialize Ruby Objects with hashes

Ruby is a wonderful language (personal opinion! :P) and one of its main features is that it strongly adopts the concepts of Object Oriented Paradigm (OOP).

More than a few times I found it compared to Smalltalk for how strongly it aligns with the over mentioned concepts.

One of the basic good practices on which the OOP funds its roots is to minimize dependencies between objects.

Continue reading “Initialize Ruby Objects with hashes”

It’s all about the context…or better, $this->context!

It has great power and it should always be considered.

It’s the context.

No matter what, it always influences the topic under discussion, be it a specific dissertation, a discussion with other people or a PrestaShop (PS) module.

Well in the last case I learned it the hard way.

Continue reading “It’s all about the context…or better, $this->context!”

Playing with POP

A couple of weeks ago Facebook shared a video with some behind the curtains details about the realisation of Paper, their iOS new fancy client.

Among the talks a bomb was released: they were going to open source their animation framework POP, and they finally did!

POP it has been released for iOS and OSX, it can animate everything, not only CGLayers, you can even animate volume or other object’s properties.

And to whet your appetite before heading to the repo check Codeplease’s posts on POP