repeat
  • 23 May 2023
  • Dark
    Light
  • PDF

repeat

  • Dark
    Light
  • PDF

Article summary

repeat Task Purpose

The repeat task is used to copy a string a specified number of times. A new string is constructed from the original string containing the specified number of copies concatenated together.

Potential Use Case

Suppose you have a name in a list, and you need to fill out predefined spaces with the same name. You could use this task to repeat the name as required.

Properties

Input and output parameters are shown below.

Incoming Type Description
str String Required. The string to copy.
count Number Required. The number of times to repeat (copy) the string.


Outgoing Type Description
repeatedString String A new string containing the specified number of copies of the given string.

Example

In this example, the incoming Reference variable is "Hello World" and the count number is "2", which means the task will return a repeated copy of the str variable two times.

repeatTask

The result of this task creates a new string that has been repeated the desired number of times; essentially the original str followed by a repeated copy of itself: Hello WorldHello World.

repeatTask Result


Was this article helpful?

What's Next
Changing your password will log you out immediately. Use the new password to log back in.
First name must have atleast 2 characters. Numbers and special characters are not allowed.
Last name must have atleast 1 characters. Numbers and special characters are not allowed.
Enter a valid email
Enter a valid password
Your profile has been successfully updated.