I have following json file and I need a way to randomly select json data and prints its value.
json file :
{
"base": [{"1": "add"},{"2": "act"}],
"past": [{"add": "added"},{"act": "acted"}],
"past-participle": [{"add": "added"},{"act": "acted"}],
"s-es-ies": [{"add": "adds"},{"act": "acts"}],
"ing": [{"add": "adding"},{"act": "acting"}]
}
example
user_input = 'past' >> past
code randomly selects 'add' or 'act' from past >> add
prints out its value >> added