Write function named duplicatestringastring value that


Write function, named duplicateString(aString, value) that takes, as arguments, a string and a positive integer, and returns the string created by writing each letter in the string the number of times that corresponds to the value specified. For example,

>>>duplicateString("word", 3)

should return the string "wwwooorrrddd" and

>>>duplicateString("hello", 1)

should return the string "hello".

Solution Preview :

Prepared by a verified Expert
Basic Computer Science: Write function named duplicatestringastring value that
Reference No:- TGS02749829

Now Priced at $10 (50% Discount)

Recommended (97%)

Rated (4.9/5)