NCV.cu: include <algorithm>

It's needed for std::max.
Merge pull request #3421 from SpecLad:ncv-algorithm