Skip to main content
2 of 6
added 188 characters in body
daavko
  • 844
  • 6
  • 11

Retina, 44 25 bytes

+`'([^']).(.*).(.)
$1$2$3

Assumes input in following format (in unary - counting character: '):
{number of repeats}{string}
For example: '''''''ABCDEFGHIJKLMNOP
There is no space between number of repeats and the string.

Thanks @MartinBüttner for shaving off 19 bytes!

Try it online!

daavko
  • 844
  • 6
  • 11