code_quizzer
code_quizzer copied to clipboard
Alternate answers for Ruby Array Conditionals Loops
Hello here the question:
First
lyric = ["laughter", "it's", "free"] Get the first element of the lyric Array.
The Answer is lyric[0]
and should include lyric.first
Second
lyric = ["laughter", "it's", "free"] Get the last element of the lyric Array.
The Answer is lyric[-1]
or lyric[2]
and should include lyric.last