Convert the dictionary below to a JSON string named years_json. Specify the indent as 4.
Json module
Years and years
Report a typo
Write a program in Python 3
import json
years = {2020: "leap year", 2021: "regular year", 2022: "regular year",
2023: "regular year", 2024: "leap year"}
# convert years to JSON string
___
By continuing, you agree to the JetBrains Academy Terms of Service as well as Hyperskill Terms of Service and Privacy Policy.
Create a free account to access the full topic
By continuing, you agree to the JetBrains Academy Terms of Service as well as Hyperskill Terms of Service and Privacy Policy.