logic.rb revision a0bfc54a3228b92b67f0338efd46be08265cd26f