CodeLab Solution 51831
Given a variable , polygon_sides, that is associated with a dictionary that maps names of polygons to number of sides, create a new dictionary that maps number of sides to polygon names, and associate it with a variable n_polygons.
[cc lang=”PYTHON”]
n_polygons={x:y for y,x in polygon_sides.items()}
[/cc]
facebook