Auto in C++

Can someone explain me quiet quickly and shortly what “auto” is in C++?

The section on Wikipedia actually explains it quite nicely :slight_smile:

There are a couple of other contexts where it can be used:


but the first one - type inference for declarations - is the most common and useful.

4 Likes