Revert "Replace deprecated max() operator by maximum()"

This reverts commit bd413f248e98f298a6e9b46efb7e636861c261c4.