human
Write a function to find the maximum value in a given heterogeneous list. Here is a solution in Python: ... What is a Python code to find the maximum value in a given heterogeneous list?
assistant
#Here is Python code to find the maximum value in a given heterogeneous list.
 def max_val(listval):
     max_val = max(i for i in listval if isinstance(i, int)) 
     return(max_val)