Added max increasing span and rand(m, n) rand(max)