6 kyu

String transformer

3,591 of 6,917tonytangau

Description:

Given a string, return a new string that has transformed based on the input:

  • Change case of every character, ie. lower case to upper case, upper case to lower case.
  • Reverse the order of words from the input.

Note: You will have to handle multiple spaces, and leading/trailing spaces.

For example:

"Example Input" ==> "iNPUT eXAMPLE"

You may assume the input only contain English alphabet and spaces.

Fundamentals

More By Author:

Check out these other kata created by tonytangau

Stats:

CreatedJan 13, 2017
PublishedJan 13, 2017
Warriors Trained10204
Total Skips944
Total Code Submissions28143
Total Times Completed6917
JavaScript Completions3591
PHP Completions458
Python Completions2353
Haskell Completions56
Ruby Completions293
CoffeeScript Completions12
Crystal Completions14
TypeScript Completions317
Total Stars140
% of votes with a positive feedback rating93% of 1183
Total "Very Satisfied" Votes1044
Total "Somewhat Satisfied" Votes112
Total "Not Satisfied" Votes27
Total Rank Assessments12
Average Assessed Rank
6 kyu
Highest Assessed Rank
6 kyu
Lowest Assessed Rank
7 kyu
Ad
Contributors
  • tonytangau Avatar
  • anter69 Avatar
  • donaldsebleung Avatar
  • Chrono79 Avatar
  • Blind4Basics Avatar
  • KenKamau Avatar
  • MattZ306 Avatar
  • abrenon Avatar
  • user8436785 Avatar
  • saudiGuy Avatar
Ad