Complete the code to access the 'age' field from the structured array.
ages = data['[1]']
To access a field by name in a structured NumPy array, use the field name as a string inside square brackets.
Complete the code to get the 'score' field from the structured array.
scores = data['[1]']
The field name is case-sensitive and must match exactly as defined in the structured array.
Fix the error in accessing the 'height' field from the structured array.
heights = data[1]'height']
Fields in structured arrays are accessed using square brackets, not dot notation.
Fill both blanks to create a dictionary of names and ages from the structured array.
result = {data['[1]'][i]: data['[2]'][i] for i in range(len(data))}To create a dictionary mapping names to ages, use the 'name' field as keys and 'age' field as values.
Fill all three blanks to create a dictionary of uppercase names and their scores if the score is above 80.
result = {data['[1]'][i].upper(): data['[2]'][i] for i in range(len(data)) if data['[3]'][i] > 80}This dictionary comprehension uses the 'name' field converted to uppercase as keys, and the 'score' field as values, filtering only scores above 80.