Last active
August 30, 2019 05:25
-
-
Save Dalmangyi/0026b67fe614ca7b6ef0b60d2237a8fe to your computer and use it in GitHub Desktop.
Dart Isolate Exam
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'dart:async'; | |
import 'dart:isolate'; | |
void main() { | |
Isolate.spawn(sendMessage, 'Hello'); | |
Isolate.spawn(sendMessage, 'Greetings'); | |
Isolate.spawn(sendMessage, 'Welcome'); | |
} | |
void sendMessage(var message) { | |
print('This is a ${message}'); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment