Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
9
Task/Repeat-a-string/MUMPS/repeat-a-string-1.mumps
Normal file
9
Task/Repeat-a-string/MUMPS/repeat-a-string-1.mumps
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
RPTSTR(S,N)
|
||||
;Repeat a string S for N times
|
||||
NEW I
|
||||
FOR I=1:1:N WRITE S
|
||||
KILL I
|
||||
QUIT
|
||||
RPTSTR1(S,N) ;Functionally equivalent, but denser to read
|
||||
F I=1:1:N W S
|
||||
Q
|
||||
3
Task/Repeat-a-string/MUMPS/repeat-a-string-2.mumps
Normal file
3
Task/Repeat-a-string/MUMPS/repeat-a-string-2.mumps
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
;Even better (more terse)
|
||||
S x="",$P(x,"-",10)="-"
|
||||
W x
|
||||
Loading…
Add table
Add a link
Reference in a new issue