I'm trying to learn d so I started with hello world, and tried to expand a little on it.
import std.stdio;
import core.thread;
void main(string[] args){
writeln("Hello World!");
Thread.sleep(dur!("seconds")(5));
writeln("Press enter key to exit...");
writeln(readln());
}
so I expect my output to be the following
Hello World!
Press enter key to exit...
//input "abcd"
abcd
but instead I get this
//input "abcd"
Hello World!
Press enter key to exit....
abcd
the sleep function even gets skipped. What is happening?