Python find min & max of two lists

list, python

Solution

Arguably the most readable way is

max(l_one + l_two)

or

min(l_one + l_two)

It will copy the lists, though, since `l_one + l_two` creates a new list. To avoid copying, you could do

max(max(l_one), max(l_two))
min(min(l_one), min(l_two))

Problem

I have two lists such as: ``` l_one = [2,5,7,9,3] l_two = [4,6,9,11,4] ``` ...and I need to find the min and max value from both lists combined. That is, I want to generate a single min and a single max value. My question is - what is the most pythonic way to achieve this? Any help much appreciated.

Original source