Shuffle String
Easy
Strings
Array
String
Given string s and indices[], return shuffled string where s[i] goes to position indices[i].
Constraints
len ≤ 100
Examples
Example 1:
Input: codeleet
4 5 6 7 0 2 1 3
Output: leetcode
Example 2:
Input: abc
0 1 2
Output: abc
Tests:
Runtime:
Memory:
Test
Input:
Expected:
Got:
Click Run Code to test against sample cases, or Submit to test against all cases.
▲ Console