to use max in VS <algorithm> needs to be included and <type> as to be used.