To find an app - 'contains'

Screen Link:

My Code:

for app in android_final: 
    if app=='Spotify':

What I expected to happen:

What actually happened:


I expected to find the Spotify app for Android, but it doesn´t exist in the csv, something that I don’t really understand why is not included.
Anyway,¿is this a good way to find an app?. An what is the alternative to `contains’ or regular expression in Python in case I wanted to filter?

What is android_final? Is it that big list of lists containing all apps? If so, then app is a list containing data about the app. If you want to access the name of the app you need to use app[0], otherwise no matter which app you look for you’ll always get an empty list because, as app is a list, app == 'Any app' will never be True.

The correct code would be:

for app in android_final: 
    if app[0] == 'Spotify':

Nonetheless, Spotify is not in the dataset. The dataset never claimed to have data about every app in the Google Play store. In fact, it contains information about a few thousand apps. According to Wikipedia, the Google Play store has over 3 million apps.

1 Like