repo.or.cz
/
parrot.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
fix codetest failure - ASSERT_ARGS does not have a ; after and
[parrot.git]
/
examples
/
tutorial
/
21_string_ops_repeat.pir
blob
c79d2fafe176dffddfba20a26e4dabc2e28d067b
1
# Copyright (C) 2007-2009, Parrot Foundation.
2
# $Id$
3
4
=head1 String Operations (continued)
5
6
PIR has a string repeat opcode, that concatenates a string with
7
itself N times.
8
9
=cut
10
11
.sub main :main
12
13
$S0 = "Hello "
14
$S1 = repeat $S0, 3
15
16
say $S1 # prints "Hello Hello Hello \n"
17
18
.end
19
20
# Local Variables:
21
# mode: pir
22
# fill-column: 100
23
# End:
24
# vim: expandtab shiftwidth=4 ft=pir:
25