Harfang's Perch

  • Posts
  • About
  • RSS
  • Atom
  • English
  • 한국어
  • What Makes Pattern Matching in Elixir So Nice?

    2017-03-15

    Many people pick pattern matching as one of the nicest features of Elixir. But it’s hard to explain why or how it is nice - it’s something experiential that arises from the combination of pattern matching and other characteristics of Elixir.

    In this post I will present a few examples of pattern matching in Elixir to describe why it is such a great feature. The target audience of this post is people with experience in object-oriented programming (OOP) but without much exposure to functional programming (FP). The post is not about an in-depth comparison between pattern matching in Elixir and pattern matching in other languages.

    Let’s get started.

    Read more
  • My Favorite Ruby Rogues Episodes - Career and Organizational Management

    2017-03-04

    Previous post was about episodes that discuss how to grow as an individual developer. This post is about episodes that discuss career management and organizational management.

    This is the last post. I’ve mostly left out episodes about specific Ruby techniques and tools, and episodes about developer communities or social responsibilities as they are more specialized interest.

    Read more
  • My Favorite Ruby Rogues Episodes - Personal Growth

    2017-02-25

    The previous post was about book club episodes. This post is about episodes that discuss methods and perspectives that can help you grow as an individual developer.

    Read more
  • My Favorite Ruby Rogues Episodes - Book Club Series

    2017-02-18

    As I taught myself to program, Ruby Rogues podcast has been invaluably helpful to me. Books and blog posts could teach me specific technological knowledge, but they couldn’t provide me a broader perspective about programming. Ruby Rogues podcast filled that gap. Charles Max Wood, the host of the show, and panelists and guests have my deepest gratitude. You can read the separate post that I wrote about Ruby Rogues here.

    When I first started writing this blog post, I wanted to pick my favorite episodes out of the 300 Ruby Rogues episodes. But as I went through the list of episodes, I realized that I liked almost all of them. They all taught me something.

    Read more
  • How to Create Minimal Elixir Web App With Plug and Cowboy and Deploy to Heroku

    2017-02-09

    This post will go through how to create a minimal web application in Elixir just using Cowboy, an HTTP server for Erlang/OTP, and Plug, a composable web middleware for Elixir, and deploy it to Heroku.

    Since you are knowledgeable enough to know about and look for a barebone approach, I assume that you have a basic familiarity with both Elixir and web development.

    Read more
  • Quora Q&A Session With David Heinemeier Hansson (Jan 25, 2017)

    2017-01-27

    This is a copy of a Q&A session with David Heinemeier Hansson hosted by Quora on January 25, 2017. Here is the link to the original Quora site. All questions are posted by Quora users and answered by DHH.

    Read more
  • Technical Skills Are Not Enough

    2017-01-25

    Programming is not an easy skill to learn. This is evidently clear when you try to teach absolute beginners how to program. It requires a tremendous amount of underlying knowledge and training just to get them started with it. More advanced topics such as algorithmic analysis, hardware specific optimization, or distributed concurrent programming, take even more time and dedication to learn. It is no wonder that technical skills are so highly regarded among programmers.

    Read more
  • Various Quicksort Implementations in Elixir

    2017-01-20

    Elixir has built-in sort functions Enum.sort/1 and Enum.sort/2. For list type, it calls Erlang :lists.sort/1 and :lists.sort/2 that use merge sort algorithm. For other Elixir types that implement Enumerable protocol, Elixir implements its own merge sort. Here’s the link to the source code.

    Since Elixir list is implemented as singly linked list, merge sort is the obvious choice for sorting. But I’ve never implemented quicksort with a linked list before, so I decided to give it a try with Elixir.

    Read more
  • How to Enable Tail Call Optimization in Ruby

    2017-01-02

    This post assumes basic understanding of recursion and Ruby.

    What is tail call optimization

    Tail call optimization (TCO) is an optimization strategy for tail-recursive procedures. It is useful in preventing stack overflow when using recursion because it limits the call stack size of a recursive procedure to one.

    Read more
  • Basics of Ruby Method Dispatch System (Part 2)

    2016-12-24

    In this post, I will explain the basics of how a method call works in Ruby. I’ll assume that readers have some familiarity with Ruby language.

    The post is in two parts. The first part covers what you need to know about typical Ruby program. It covers: ancestors hierarchy, class inheritance, and module include and prepend.

    The second part digs into tools that are used less often. It covers: singleton method, singleton class, and class methods.

    Read more
1 2 3 4 5