Problem · Array
Generate Array
Learn this problemProblem statement
Given a String array, return the output array in form where each word is first letter of that word with last letter of next (i+1)th index word.
eg = ["cat","dog","flower","bed"]
Output = ["cg","dr","fd","bt"]
Hi! Uber assessment comes with 4 coding questions.
Function
generateArray(words: String[]) → String[]Examples
Example 1
words = ["cat", "dog", "flower", "bed"]return = ["cg", "dr", "fd", "bt"]:)
More Uber problems
- Last Truck to Leave the LaneOA · Seen Jul 2026
- Chain of CommandOA · Seen Jul 2026
- Jump Game with Prime-3 StepsOA · Seen Jun 2026
- Total Palindrome Substring CostOA · Seen Jun 2026
- Earliest Time All Users Are ConnectedPHONE SCREEN · Seen May 2026
- Tournament Rounds by RankPHONE SCREEN · Seen May 2026
- Farthest Seat AssignmentONSITE INTERVIEW · Seen May 2026
- Convex Function MinimizationPHONE SCREEN · Seen May 2026