UPDATE a fork of this gist has been used as a starting point for a community-maintained "awesome" list: machine-learning-with-ruby Please look here for the most up-to-date info!
- liblinear-ruby: Ruby interface to LIBLINEAR using SWIG
# Codility challenge for base -2 with the least significative bit at the left. | |
# | |
# In base -2 integers are represented by sequences of bits in the following way. | |
# Bits are ordered from the least to the most significant. Sequence B of N bits | |
# represents the number: sum(B[i] * (-2)^i for i = 0..N-1). The empty sequence represents 0. | |
# Note that such representation is suitable for both positive and negative numbers. | |
# NOTE: Remember negative division returns the floor. http://python-history.blogspot.mx/2010/08/why-pythons-integer-division-floors.html | |