Skip to content

Instantly share code, notes, and snippets.

@AntelopeSalad
Last active August 29, 2015 14:00
Show Gist options
  • Save AntelopeSalad/eaf8a0a4eda7106beec4 to your computer and use it in GitHub Desktop.
Save AntelopeSalad/eaf8a0a4eda7106beec4 to your computer and use it in GitHub Desktop.
# [1, 4, 2] vs [1, 5, 0] => [false, true, false]
# [3, 8, 4] vs [4, 4, 2] => [true, false, false]
# [2, 6, 9] vs [2, 6, 15] => [false, false, true]
# solution:
a.zip(b).map { |a, b| a < b }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment