I really need help. Am hooked up here! How did these codes come about?. I need an explanation. Thanks.
Hopefully my explanation answers your question.
Extract function returns a list of column values from your app dataset based on the index number you provide. So in this example you are using index 11 to extract the genre column.
Freq table function returns a dictionary of genres with their count (frequency table). Loop through all values in genres list. The IF statement checks to see if the genre is already in the dictionary if so increase count by 1 else create new key for the genre and set count to 1.
What issue do you have in particular? Maybe elaborate about your problem a bit more so we can help you. Beside the detailed explanation mau_foo give, if you have identical code to the solution but miss some indents the code will not work. So maybe that is what giving you trouble?