(String[] args)
| 11 | } |
| 12 | |
| 13 | public static void main(String[] args) { |
| 14 | assert rotation("abcdef", 2).equals("cdefab"); |
| 15 | |
| 16 | char[] values = "abcdef".toCharArray(); |
| 17 | rotation(values, 2); |
| 18 | assert new String(values).equals("cdefab"); |
| 19 | } |
| 20 | |
| 21 | /** |
| 22 | * Move {@code n} characters in front of given string to the end of string |