Skip to content

Latest commit

 

History

History
35 lines (22 loc) · 2.93 KB

10-double-char.md

File metadata and controls

35 lines (22 loc) · 2.93 KB

Problem:

Given a string, you have to return a string in which each character (case-sensitive) is repeated once.

double_char("String") ==> "SSttrriinngg"

double_char("Hello World") ==> "HHeelllloo WWoorrlldd"

double_char("1234!_ ") ==> "11223344!!__ "

double_char("String") ==> "SSttrriinngg"

double_char("Hello World") ==> "HHeelllloo  WWoorrlldd"

double_char("1234!_ ") ==> "11223344!!__  "
doubleChar("String") ==> "SSttrriinngg"

doubleChar("Hello World") ==> "HHeelllloo  WWoorrlldd"

doubleChar("1234!_ ") ==> "11223344!!__  "
doubleChar "String" ==> "SSttrriinngg"

doubleChar "Hello World" ==> "HHeelllloo  WWoorrlldd"

doubleChar "1234!_ " ==> "11223344!!__  "
doubleChar "String" ==> "SSttrriinngg"

doubleChar "Hello World" ==> "HHeelllloo  WWoorrlldd"

doubleChar "1234!_ " ==> "11223344!!__  "
DoubleChar("String") == "SSttrriinngg"

DoubleChar("Hello World") == "HHeelllloo  WWoorrlldd"

DoubleChar("1234!_ ") == "11223344!!__  "

Good Luck!

Solution