Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # cities = ['berlin', 'tokyo']
- # # 0 1
- # cities[1]
- students = [ "Peter", "Mary", "George", "Emma" ]
- student_ages = [ 24 , 25 , 22 , 20 ]
- students.each_with_index do |student, index|
- age = student_ages[index]
- puts "#{student} is #{age} years old"
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement