CDE
This commit is contained in:
parent
518da4a923
commit
764da6cbbb
6144 changed files with 83610 additions and 11 deletions
17
Task/Concurrent-computing/Forth/concurrent-computing.fth
Normal file
17
Task/Concurrent-computing/Forth/concurrent-computing.fth
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
require tasker.fs
|
||||
require random.fs
|
||||
|
||||
: task ( str len -- )
|
||||
64 NewTask 2 swap pass
|
||||
( str len -- )
|
||||
10 0 do
|
||||
100 random ms
|
||||
pause 2dup cr type
|
||||
loop 2drop ;
|
||||
|
||||
: main
|
||||
s" Enjoy" task
|
||||
s" Rosetta" task
|
||||
s" Code" task
|
||||
begin pause single-tasking? until ;
|
||||
main
|
||||
Loading…
Add table
Add a link
Reference in a new issue