Input Format
The first line of input contains the space separated values of  and .
The next  lines contains  space separated integers.
Output Format
Compute the min along axis  and then print the max of that result.

hackerrank min and max problem solution in python programming

Problem solution in Python 3 programming language.

import numpy
N, M = map(int, input().split())
my_array = numpy.array([ map(int, input().split()) for i in range(N) ])
print(numpy.max(numpy.min(my_array, axis = 1)))

Second solution

import numpy as np
print(np.max(np.min(np.array([input().split() 
for _ in range(int(input().split()[0]))],int),axis=1)))

Problem solution in Python 2 programming language.

import numpy
N, M = map(int, raw_input().split())
my_array = numpy.array([ map(int, raw_input().split()) for i in range(N) ])
print numpy.max(numpy.min(my_array, axis = 1))