Students, please be sure to log in. This site does not use cookies and does not track/store work submitted when not signed in.
Unit 6 Problems
Java Reference Sheet
Pairs
Objective(s): Practice manipulating elements of an array in the context of a loop.
Given two arrays of String
objects, complete the method to return a new array consisting of all the unique pair combinations between the two arrays.
Example:
pairs({"Hi","Good"}, {"There","Bye"}) -> { "HiThere","HiBye","GoodThere","GoodBye" }
pairs({"a","b"}, {"c","d"}) -> { "ac","ad","bc","bd" }