You are given a string of words (x), for each word within the string you need to turn the word 'inside out'. By this I mean the internal letters will move out, and the external letters move toward the centre.
If the word is even length, all letters will move. If the length is odd, you are expected to leave the 'middle' letter of the word where it is.
An example should clarify:
'taxi' would become 'atix' 'taxis' would become 'atxsi'
'매일매일개발 > Codewars' 카테고리의 다른 글
codewars #68 Predict your age! (7kyu) (0) | 2018.06.27 |
---|---|
codewars #67 Predict your age! (7kyu) (0) | 2018.06.26 |
codewars #65 Split Strings (6kyu) (0) | 2018.06.21 |
codewars #64 Strip Comments (4kyu) (0) | 2018.06.20 |
codewars #63 Sort two arrays (5kyu) (0) | 2018.06.19 |