下面是完整代码:
```python
fig, ax = plt.subplots()
# Plot a bar-chart of gold medals as a function of country
ax.bar(medals.index, medals["Gold"])
# Set the x-axis tick labels to the country names and rotate them by 90 degrees
ax.set_xticklabels(medals.index, rotation=90)
# Set the y-axis label
ax.set_ylabel("Number of medals")
plt.show()
```