Edd Mann Developer

Using Constraint-based Ordering in PHP

An interesting problem arose last week when we wished to generate a listing of recently completed jobs (along with their shortlist fees). Upon review of some earlier attempts, we did not like the aesthetics present when many of a particular shortlist fee were clustered together (i.e. two or more adjacent jobs with the same shortlist fee). What we were instead looking for was to create a constraint-based ordering that when applied to the recently completed jobs, would give an even distribution of shortlist fees (data-set permitting).

Throttling and Debouncing Function Invocation in JavaScript

Whilst working on resolving a recent JavaScript event handler bug, it deemed necessary to implement a form of throttling to make sure a race-condition would not occur. Throughout the fix I found myself seeking a clear definition of what both throttling and debouncing a function actually entailed; as it can be very easy to mix the two subtly different concepts.

AVL Trees in Clojure

An AVL tree is a self-balancing binary search tree, where-by the height of a node’s children differ by at most one. In the event that this property is violated a re-balancing process takes place.

Anagram Solver in Clojure

This past week discussion around solving anagrams was brought up - I thought it would be interesting to devise a couple of methods for computational achieving such a task. Providing an anagram string and a dictionary file, I wished to be returned all possible matching words from the dictionary.

Maybe in JavaScript

Recently I have been delving into the concepts of Functors and Monads. There are many good resources available online that will do a far better job of explaining these concepts than me, however, I do wish to document an example Maybe type I have implemented in JavaScript. Again, there are many good external resources which highlight the characteristics and power of using such a type, so I will direct your attention to those if you wish to learn more.