Last active
August 29, 2015 14:11
-
-
Save ymurase/55cca64b67d3991ff1cd to your computer and use it in GitHub Desktop.
x10で外部プロセス実行
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 x10.io.Console; | |
import x10.lang.Runtime; | |
public class RunProgram { | |
public static def main(args: Rail[String]) { | |
val times: Long = 10; | |
for(var k: Long = 0; k< times; k++) { | |
Console.OUT.println(" I am launching "+ k); | |
val t = Runtime.execForWrite("sleep 5 && echo " + k); | |
// t.close(); | |
} | |
Console.OUT.println("Done!" ); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment