tech on the net

MS Excel: REPT Function (WS)

In Microsoft Excel, the REPT function returns a repeated text value a specified number of times.

Syntax

The syntax for the REPT function is:

REPT( text, number )

text is the text value to repeat.

number is the number of times to repeat the text value.

Applies To

Type of Function

Worksheet Function Example

Let's take a look at an example to see how you would use the REPT function in a worksheet:

Microsoft Excel

Based on the Excel spreadsheet above, the REPT function would return the following:

=REPT(A1, 3) would return "abcdabcdabcd"
=REPT(A2, 2) would return "isis"
=REPT("apples", 2) would return "applesapples"