From 29aaf618d6c42389b0c62834d2ab16d996d7c025 Mon Sep 17 00:00:00 2001 From: Edvard Pedersen Date: Mon, 14 Sep 2020 15:09:37 +0200 Subject: [PATCH] fix missing quotation marks around string --- book_src/chapters/dictstring.do.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/book_src/chapters/dictstring.do.txt b/book_src/chapters/dictstring.do.txt index 70ac47d..83dcfa3 100644 --- a/book_src/chapters/dictstring.do.txt +++ b/book_src/chapters/dictstring.do.txt @@ -57,7 +57,7 @@ print(d['Norway']) !ec To extend the dictionary with new values, we can simply write !bc pycod -d['Germany'] = Berlin +d['Germany'] = 'Berlin' !ec Notice this important difference between a list and a dictionary. For a list we had to use `append()` to add new elements. A dictionary has no `append` method, and to extend it we simply introduce a new key