summaryrefslogtreecommitdiffstatshomepage
path: root/tests/basics/dict_update.py
diff options
context:
space:
mode:
authorDamien George <damien.p.george@gmail.com>2014-01-19 17:41:01 +0000
committerDamien George <damien.p.george@gmail.com>2014-01-19 17:41:01 +0000
commit5f7e8dc176661b49e12a0d8425101799ff176d19 (patch)
tree0fd3daa844300d62a3836b5bb16c3c7be2b875cb /tests/basics/dict_update.py
parentb2ebb161d494864cdbee05ee8b74a775845e238e (diff)
parentdb796ef84d1737edc4ee44f1b53ff0c1fddb349c (diff)
downloadmicropython-5f7e8dc176661b49e12a0d8425101799ff176d19.tar.gz
micropython-5f7e8dc176661b49e12a0d8425101799ff176d19.zip
Merge branch 'master' of github.com:micropython/micropython
Diffstat (limited to 'tests/basics/dict_update.py')
-rw-r--r--tests/basics/dict_update.py10
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/basics/dict_update.py b/tests/basics/dict_update.py
new file mode 100644
index 0000000000..e7ae0bd965
--- /dev/null
+++ b/tests/basics/dict_update.py
@@ -0,0 +1,10 @@
+d = {1:2, 3:4}
+print(d)
+d.update(["ab"])
+print(d[1])
+print(d[3])
+print(d["a"])
+print(len(d))
+d.update([(1,4)])
+print(d[1])
+print(len(d))