auto and typeof

This lesson will teach you about the use of auto and typeof in D language.

We'll cover the following...

auto #

At times, we have to declare variables that need type declaration on both sides of the = operator. For example, when declaring a file variable (don’t get confused with the type of the variable, we will cover this variable type in a later chapter), we have to repeat the name of the type on both sides of the = operator:

File file = File("student_records", "w");
...