For example, dict ={} dict[0930] = ['s', 'a', 'g']
dict = {0930 : ['s', 'a', 'g']} It's an index
Save this dict value and
next time dict[1000] = ['a', 'b', 'k'] When you enter
dict = {0930 : ['s', 'a', 'g'], 1000 : ['a', 'b', 'k']} What is the way to add it as?<
python
Dictionary is an item addition if the key is not duplicated.
Just do as you say.
But don't use dict as a variable name. The class name of the dictionary data type.
>>> d = {}
>>> d['0930'] = ['s','a','g']
>>> d
{'0930': ['s', 'a', 'g']}
>>> d['1000'] = ['a','b','k']
>>> d
{'0930': ['s', 'a', 'g'], '1000': ['a', 'b', 'k']}
563 PHP ssh2_scp_send fails to send files as intended
564 Uncaught (inpromise) Error on Electron: An object could not be cloned
572 GDB gets version error when attempting to debug with the Presense SDK (IDE)
803 When building Fast API+Uvicorn environment with PyInstaller, console=False results in an error
© 2024 OneMinuteCode. All rights reserved.