This site is supported by donations to The OEIS Foundation.
Template:~Repeat~0
From OeisWiki
Helper function template (used by {{~Repeat~1}}) for the {{repeat}} typing-aid template.
Count in [0..20] as first argument, character string as second argument.
Tests
Examples with valid input
Note that when the last character of text is a space instead of the final space is lost (look at {{~Repeat~1}}, which does repeated calls of {{~Repeat~0}}.)
Code Result {{~Repeat~0|0|ab}} {{~Repeat~0|1|ab}} ab {{~Repeat~0|5|ab}} ababababab {{~Repeat~0|5|ab }} ab ab ab ab ab {{~Repeat~0|5|a b}} a ba ba ba ba b {{~Repeat~0|5|ab }} ab ab ab ab ab {{~Repeat~0|10|{{=}}}} ========== {{~Repeat~0|10|a}} aaaaaaaaaa {{~Repeat~0|15|a}} aaaaaaaaaaaaaaa {{~Repeat~0|20|a}} aaaaaaaaaaaaaaaaaaaa
Examples with invalid input
Code Result {{~Repeat~0|21|a}} ~Repeat~0 error: First argument must be an integer in [0..20] {{~Repeat~0|-1|a}} ~Repeat~0 error: First argument must be an integer in [0..20]