Re: readf interferes with readln

2017-04-27 Thread Bastiaan Veelo via Digitalmars-d-learn
On Thursday, 27 April 2017 at 08:37:26 UTC, ketmar wrote: Bastiaan Veelo wrote: Hi, I am having trouble explaining the following to someone learning D. Can someone explain why readln has different behaviour when it is preceded by readf? Suppose we want to not end the program before the

Re: readf interferes with readln

2017-04-27 Thread ketmar via Digitalmars-d-learn
Bastiaan Veelo wrote: Hi, I am having trouble explaining the following to someone learning D. Can someone explain why readln has different behaviour when it is preceded by readf? Suppose we want to not end the program before the user presses Enter by having readln at the end of main():

readf interferes with readln

2017-04-27 Thread Bastiaan Veelo via Digitalmars-d-learn
Hi, I am having trouble explaining the following to someone learning D. Can someone explain why readln has different behaviour when it is preceded by readf? Suppose we want to not end the program before the user presses Enter by having readln at the end of main(): ``` import std.stdio;