Run scripts

In the project directory, you can run:

bundle install

to install dependencies

bundle exec rspec

to run tests

Challenge 1

str = 'Pressuuuuuure' LongestString.new(str).call outputs = 'uuuuuu'

Challenge 2

arr = [2, -4, 6, 8, -10, 100, -6, 5] PositionSubarray.new(arr).call outputs = '2,5'

Challenge 3

str = ' fly me   to   the moon   ' StringLengthLastWord.new(str).call outputs = 4

Challenge 5

arr_a, arr_b = [1,2,3], [3,4] SymmetricDifferenceArray.new(arr_a, arr_b) outputs = [1,2,4]