| about | help | code help+videos | done | prefs |
Given a String of at least three characters return the String unchanged unless it is an odd length, then return a String with the same first and last characters but all the other characters are replaced by the middle character of the parameter. oddCenter("ABC") → "ABC" oddCenter("ABCDE") → "ACCCE" oddCenter("ABCD") → "ABCD" ...Save, Compile, Run (ctrl-enter) |
Progress graphs:
Your progress graph for this problem
Random user progress graph for this problem
Random Epic Progress Graph
Difficulty: 200
Copyright Nick Parlante 2017 - privacy