Ruby implementation for a checkout system with pricing rules.