all tasks
This commit is contained in:
parent
b83f433714
commit
68f8f3e56b
14735 changed files with 178959 additions and 0 deletions
13
Task/Tokenize-a-string/Mercury/tokenize-a-string.mercury
Normal file
13
Task/Tokenize-a-string/Mercury/tokenize-a-string.mercury
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
:- module string_tokenize.
|
||||
:- interface.
|
||||
|
||||
:- import_module io.
|
||||
:- pred main(io::di, io::uo) is det.
|
||||
|
||||
:- implementation.
|
||||
:- import_module list, string.
|
||||
|
||||
main(!IO) :-
|
||||
Tokens = string.split_at_char((','), "Hello,How,Are,You,Today"),
|
||||
io.write_list(Tokens, ".", io.write_string, !IO),
|
||||
io.nl(!IO).
|
||||
Loading…
Add table
Add a link
Reference in a new issue