2014-4: Space The Final Frontier

Write code that removes extraneous (leading, trailing, and multiple) spaces from a character array.

Examples

Implementation

You can also run the tests via ⌘/shift + enter