Skip to content

rept

Repeat a string a specified number of times.

v = rept(text, number_times)

Returns text concatenated with itself number_times times. With number_times = 0, returns an empty string.

rept('-', 5) % '-----'
rept('ab', 3) % 'ababab'
  • strcat — Concatenate strings horizontally.