Formatted Input
This lesson explains how the format of data can be specified at the time of input.
We'll cover the following...
What is formatted input? #
It is possible to specify the format of the data expected to be read as input using readf
. It specifies both the data that should be read and the characters that should be ignored.
D’s input format specifiers are similar to the ones present in the C language.
As previously used, the format specifier " %s"
reads the data according to the type of the variable. For example, since the type of the variable used in readf
...
Access this course and 1400+ top-rated courses and projects.