Skip to content
Advertisement

How to add multiple values in dictionary for a key [closed]

I am trying to write a python code where i want to take multiple or 3 number inputs from user for one key in dictionary . Can anyone please help . Appreciate in advance

I think output will be as given below . For key “ABC” assigned/values are 67,68,69.

{ABC : [67, 68, 69]}

JavaScript

Advertisement

Answer

here if you want to add multiple numbers

JavaScript

here for 3 numbers only

JavaScript
User contributions licensed under: CC BY-SA
4 People found this is helpful
Advertisement