tasks a-s
This commit is contained in:
parent
47bf37c096
commit
b83f433714
12433 changed files with 156208 additions and 123 deletions
4
Task/Copy-a-string/Standard-ML/copy-a-string-1.ml
Normal file
4
Task/Copy-a-string/Standard-ML/copy-a-string-1.ml
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
val src = "Hello";
|
||||
val srcCopy = CharArray.array (size src, #"x"); (* 'x' is just dummy character *)
|
||||
CharArray.copyVec {src = src, dst = srcCopy, di = 0};
|
||||
src = CharArray.vector srcCopy; (* evaluates to true *)
|
||||
2
Task/Copy-a-string/Standard-ML/copy-a-string-2.ml
Normal file
2
Task/Copy-a-string/Standard-ML/copy-a-string-2.ml
Normal file
|
|
@ -0,0 +1,2 @@
|
|||
val srcCopy2 = CharArray.array (CharArray.length srcCopy, #"x"); (* 'x' is just dummy character *)
|
||||
CharArray.copy {src = srcCopy, dst = srcCopy2, di = 0};
|
||||
Loading…
Add table
Add a link
Reference in a new issue