Skip to content

Instantly share code, notes, and snippets.

@anthonygharvey
Created August 15, 2019 01:46
Show Gist options
  • Save anthonygharvey/8407f1314a745b033d16691a06d1f893 to your computer and use it in GitHub Desktop.
Save anthonygharvey/8407f1314a745b033d16691a06d1f893 to your computer and use it in GitHub Desktop.
list_1 = ['apple', 'orange', 'grape']
list_2 = ['strawberry', 'apple']
combined_list = (list_1 + list_2).uniq
combined_list #=> ["apple", "orange", "grape", "strawberry"]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment