about | help | code help+videos | done | prefs |
transpose
You want to transpose two letters in a String. In addition to the input String, you have indices x and y which represent the position of the characters you need to swap. Returned the String with the chars swapped. transpose("hello", 0, 4) → "oellh" ...Save, Compile, Run (ctrl-enter) |
Progress graphs:
Your progress graph for this problem
Random user progress graph for this problem
Random Epic Progress Graph
Difficulty: 200 Post-solution available
Copyright Nick Parlante 2017 - privacy