Min and Max to list within list. Is that even possible?

Screen Link: Скриншот 10-07-2021 19.44.34.jpg - Google Drive Loom | Free Screen & Video Recording Software

My Code:

use max(int(apps_data[2][2])) but as a whole column as a list.

What I expected to happen:
Please help me to understand the command max() and how it can be applied to multiple ints within list AppleStore.csv
I want to find min and max with just one command min and apply it to list within list

Hello Matro,
I am not very sure what are you trying to achieve but let me try to help:

  • 1-First of all in the screenshot attached your code max(int(apps_data[2:2])) wont return anything, because remember that list slicing starts from the first index up to but not including the second index. So in this case it will return an empty string and therefore the max function returns nothing.

  • 2-the function max() is as easy as it sounds, it returns the maximum of the values specified, the part that is confusing you is what values to pass to the max() function. Here we want the third column (which is index 2 due to zero indexing of Python) of all rows, that’s why we used a for loop to go through all rows and extract the the value present in the third column.

  • 3-In later courses you will learn an easy way on how to apply the max function using only one command as you wish to do so don’t worry about this now. The goal now is to learn the basics of python and it’s logic and how to use it’s built-in data structures.

Good luck and keep learning :muscle: