StringTools - Maple Help

Online Help

All Products    Maple    MapleSim


Home : Support : Online Help : Programming : Names and Strings : StringTools Package : Constructors : StringTools/Repeat

StringTools

  

Repeat

  

repeatedly catenate a string with itself

 

Calling Sequence

Parameters

Description

Examples

Calling Sequence

Repeat( s, n )

Parameters

s

-

string

n

-

non-negative (32-bit) integer

Description

• 

The Repeat(s,n) command catenates the string s with itself n times. If either n=0 or s=, then the empty string  is returned.

• 

The Repeat command implements the powering operation in the free monoid generated by the nonzero bytes.

Examples

withStringTools:

Repeatabc,0

(1)

Repeatabc,5

abcabcabcabcabc

(2)

Repeat,5

(3)

Repeat,0

(4)

See Also

length

StringTools

StringTools[Fill]

StringTools[IsPrimitive]

 


Download Help Document

Was this information helpful?



Please add your Comment (Optional)
E-mail Address (Optional)
What is ? This question helps us to combat spam