Skip to content


Subversion checkout URL

You can clone with
Download ZIP
Tree: 06af1c69d8
Fetching contributors…

Cannot retrieve contributors at this time

44 lines (27 sloc) 1.352 kB

Clojure Katas

A collection of short problems discussed and solved at Toronto Code Retreat and Toronto Coding Dojo.

Poker hand evaluator

A Clojure library designed to compare hands of 5-card Poker game. The main idea of hand comparison is taken from Peter Norvig's class Design of Computer Programs. src/dojo/poker.clj is in fact a Clojure port of Norvig's program written in Python.

Two hands are compared by hand rank. A hand rank is a tuple with the first element an integer from the range 0..8 defining the type of the hand: 8 is straight flush, 7 is four-of-a-kind, and so on. Second and (optional) third elements of the tuple are used to compare two hands of the same type. For example, [8 14] is Royal flush and it beats [8 10] which is straight flush ten high.

Bank OCR

Dining philosophers

Clojure STM in action.

Inserting parentheses

Lists and symbols manipulation.


To run test cases you need Leiningen installed

lein test


Copyright © 2012 Andrey Paramonov

Distributed under the Apache License, Version 2.0.

Jump to Line
Something went wrong with that request. Please try again.