{"id":25930,"date":"2020-12-13T17:05:30","date_gmt":"2020-12-14T01:05:30","guid":{"rendered":"https:\/\/careerkarma.com\/blog\/?p=25930"},"modified":"2022-07-20T08:35:08","modified_gmt":"2022-07-20T15:35:08","slug":"python-dictionary","status":"publish","type":"post","link":"https:\/\/careerkarma.com\/blog\/python-dictionary\/","title":{"rendered":"Python Dictionary: A Guide for Beginners"},"content":{"rendered":"\n<p><em>A Python dictionary stores data in key-value pairs. A key is a label for a value. Dictionaries are declared as a set of keys and values between a pair of curly brackets. The syntax for a key and value is: &#8220;key_name&#8221;: value.<\/em><\/p>\n\n\n\n<p>When you take a look at a dictionary (<em>Merriam-Webster\u2019s<\/em>, <em>Oxford<\/em>), what do you notice? It\u2019s a book or list in an app of words and their corresponding definitions and etymology:<\/p>\n\n\n\n<p><strong>careerkarma<\/strong><\/p>\n\n\n\n<p><strong>noun<\/strong> ca\u00b7\u200breer\u00b7kar\u00b7ma | \\ k\u0259-\u02c8rir-\u02c8k\u00e4r-m\u0259 \\<\/p>\n\n\n\n<p><strong>Definition<\/strong><\/p>\n\n\n\n<p><strong>Definitions go here<\/strong><\/p>\n\n\n\n<p><strong>Etymology<\/strong><\/p>\n\n\n\n<p><strong>Etymology and\/or other information goes here<\/strong><\/p>\n\n\n\n<p>In Python, dictionaries are very similar. A dictionary in Python is a data structure that holds key\/value pairs together to tell us something about the structure. This article takes a look at dictionaries and some of their built-in functions.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">What is a Python Dictionary?<\/h2>\n\n\n\n<p>A Python dictionary is key-value pairs, separated by commas, and are enclosed in curly braces. Dictionary keys must be string labels. A value can contain any data type, such as a string, an integer, or another dictionary.<\/p>\n\n\n\n<p>Dictionaries are unordered: if you want to control the order in a dictionary, use a list with square brackets instead<\/p>\n\n\n\n<p>To create a dictionary, you need to create a variable and set it equal to two curly braces. The variable can be whatever you would like to name it \u2013 in these examples we are naming it \u201cdictionary\u201d.<\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre>dictionary = {}\n \nprint(dictionary)<\/pre><\/div>\n\n\n\n<p>Here is an example dictionary with some values:<\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre>word = {\n\t&quot;name&quot;: &quot;banana&quot;,\n\t&quot;definition&quot;: &quot;a yellow fruit&quot;\n}<\/pre><\/div>\n\n\n\n<p>Our dictionary contains two keys and values. &#8220;name&#8221; and &#8220;definition&#8221; are keys and the strings that come after them are our values.<\/p>\n\n\n\n<p>Duplicate keys cannot exist in a dictionary. Each key must have a unique name.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Python Add to Dictionary<\/h3>\n\n\n\n<p>Right now, if we were to print this, it would be an empty dictionary. Let\u2019s add some stuff to it:<\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre>dictionary = {}\n \ndictionary[&quot;name&quot;] = &quot;Christina&quot;\ndictionary[&quot;favorite_animal&quot;] = &quot;cat&quot;\ndictionary[&quot;num_pets&quot;] = 1\n \nprint(dictionary)<\/pre><\/div>\n\n\n\n<p>We use the bracket notation to create the key\/value pairs. Inside the brackets is a string that identifies our dictionary key. What the dictionary key is assigned to is the value of that key.<\/p>\n\n\n\n<p>We can use the same notation to update the dictionary as well. It\u2019ll just overwrite the previous value.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Access Items in a Dictionary<\/h3>\n\n\n\n<p>We use the same notation to access items present in a dictionary.<\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre>dictionary = {}\n \ndictionary[&quot;name&quot;] = &quot;Christina&quot;\ndictionary[&quot;favorite_animal&quot;] = &quot;cat&quot;\ndictionary[&quot;num_pets&quot;] = 1\n \nprint(dictionary[&quot;name&quot;])<\/pre><\/div>\n\n\n\n<p>Using <em>dictionary<\/em>[<em>\u201cname\u201d<\/em>] accesses only the <em>name<\/em> property of the dictionary and prints that in the interpreter.<\/p>\n\n\n\n<p>You can also use the <a href=\"https:\/\/careerkarma.com\/blog\/python-dictionary-get\/\">Python dictionary get() method<\/a> to retrieve an item from a dictionary:<\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre>dictionary = {}\n\ndictionary[&quot;name&quot;] = &quot;Christina&quot;\ndictionary[&quot;favorite_animal&quot;] = &quot;cat&quot;\ndictionary[&quot;num_pets&quot;] = 1\n\nprint(dictionary.get(&quot;name&quot;))<\/pre><\/div>\n\n\n\n<p>This code prints out the value of the &#8220;name&#8221; key, which is &#8220;Christina&#8221;.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Python Remove from Dictionary<\/h3>\n\n\n\n<p>There are essentially three different ways to remove a key from a dictionary: the individual entry, all the entries, or the entire dictionary.<\/p>\n\n\n\n<p>The first method removes just the entry. We do that by accessing the key we would like to get rid of using bracket notation: <em>del<\/em><em> dictionary<\/em>[<em>\u201c&lt;key name&gt;\u201d<\/em>]<\/p>\n\n\n\n<p>Here\u2019s an example using the <em>del<\/em> statement with the key name to delete the key we have specified:<\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre>dictionary = {}\n \ndictionary[&quot;name&quot;] = &quot;Christina&quot;\ndictionary[&quot;favorite_animal&quot;] = &quot;cat&quot;\ndictionary[&quot;num_pets&quot;] = 1\nprint(dictionary)\n \n# remove entry with key 'name'\ndel dictionary[&quot;name&quot;]\nprint(dictionary) # {'favorite_animal': 'cat', 'num_pets': 1}<\/pre><\/div>\n\n\n\n<p>The second method removes all the entries in the dictionary. We do that with the method <em>dictionary.clear()<\/em>. Remember that this dictionary method is that it merely clears out the dictionary. The instance of the dictionary still remains so it can be used again.<\/p>\n\n\n\n<p>Here\u2019s an example using the <em>clear()<\/em> method:<\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre># remove all entries in dict\ndictionary.clear()  \nprint(dictionary) # {}<\/pre><\/div>\n\n\n\n<p>The last method gets rid of the entire instance of the dictionary. If we try to access the dictionary after it has been deleted, it will throw an error letting you know that it doesn\u2019t exist. Do this by using the <em>del<\/em> keyword: <em>del<\/em><em> dictionary.<\/em><\/p>\n\n\n\n<p>Here\u2019s an example using the <em>del<\/em> keyword:<\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre># delete entire dictionary\ndel dictionary \nprint(dictionary)<\/pre><\/div>\n\n\n\n<p>Your code will throw KeyError exceptions if you try to access a dictionary item that does not exist using this syntax. You can read about how to solve a KeyError in our <a href=\"https:\/\/careerkarma.com\/blog\/python-keyerror\/\">Python KeyError guide<\/a>.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">oop Through Dictionary<\/h3>\n\n\n\n<p>You can use a for\u2026in loop to loop through dictionaries in Python:<\/p>\n\n\n\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre>for key in dictionary:\n\tprint(f'{key}: {dictionary[key]}')<\/pre><\/div>\n\n\n\n<h2 class=\"wp-block-heading\">Python Dictionary Methods Glossary<\/h2>\n\n\n\n<p>We&#8217;ve prepared a list of functions often used with the Python dictionary data type. This list should help you learn how you can manipulate your dictionaries in your code.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Dictionary functions:<\/h3>\n\n\n\n<p><em>len<\/em><em>(dictionary1)<\/em>: Gives the total length of the dictionary. This is equal to the number of key-value pairs in the dictionary.<\/p>\n\n\n\n<p><em>str<\/em><em>(dictionary1)<\/em>: Produces a printable string representation of a dictionary. This is comparable to the <a href=\"https:\/\/careerkarma.com\/blog\/javascript-json\/\">JavaScript JSON stringify<\/a> method, if you are used to using JavaScript.<\/p>\n\n\n\n<p><em>type<\/em><em>(variable)<\/em>: Returns the type of the passed variable. If the passed variable is a dictionary, it will return a dictionary type.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Dictionary built-in methods<\/h3>\n\n\n\n<p><em>dictionary<\/em><em>.clear()<\/em>: Removes all elements of dictionary1. Leaves the actual dictionary intact so that it can still be used. It\u2019s just an empty dictionary.<\/p>\n\n\n\n<p><em>dictionary<\/em><em>.copy()<\/em>: Returns a shallow copy of dictionary dict. Does not mutate the original dictionary.<\/p>\n\n\n\n<p><em>dictionary<\/em><em>.fromkeys(set(), value)<\/em>: Creates a new dictionary with the parameters passed into <em>set()<\/em>, and value.<\/p>\n\n\n\n<p><a href=\"https:\/\/careerkarma.com\/blog\/python-dictionary-get\/\"><em>dictionary<\/em><em>.get(key, default = None)<\/em><\/a>: For key, returns the value or default if the key is not in the dictionary.<\/p>\n\n\n\n<p><em>dictionary<\/em><em>.has_key(key)<\/em> : Returns true if a key exists in the dictionary and false if otherwise.<\/p>\n\n\n\n<p><em>dictionary<\/em><em>.items()<\/em>: Returns dictionary\u2019s (key, value) tuple pairs in a list <em>(<\/em><em>[ <\/em><em>(key1, value1), (key2, value2), etc.])<\/em><\/p>\n\n\n\n<p><a href=\"https:\/\/careerkarma.com\/blog\/python-dictionary-keys\/\"><em>dictionary<\/em><em>.keys()<\/em><\/a>: Returns a list of keys.<\/p>\n\n\n\n<p><em>dictionary<\/em><em>.pop(\u2018name\u2019)<\/em>: Removes the key\/value pair from the dictionary. The removed item is the pop method\u2019s return value.<\/p>\n\n\n\n<p><em>dictionary<\/em><em>.<\/em><em>setdefault<\/em><em>(key, default = None)<\/em>: Similar to <em>get()<\/em>, but it will set <em>dictionary1[key]=default<\/em> if the key does not already exist in the dictionary.<\/p>\n\n\n\n<p><em>dictionary<\/em><em>.update(dictionary2)<\/em> : Merges dictionary2\u2019s key-values pairs with dictionary1.<\/p>\n\n\n\n<p><a href=\"https:\/\/careerkarma.com\/blog\/python-dictionary-values\/\"><em>dictionary<\/em><em>.values()<\/em><\/a>: Returns list of dictionary values.<\/p>\n\n\n\n<p>Use the built-in methods and functions listed above to play with the sample dictionaries outlined below.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Conclusion<\/h2>\n\n\n\n<p>A Python dictionary lets you store related values together. Data in a dictionary is stored using key-value pairs. You can add as many key value pairs in a dictionary as you want.<\/p>\n\n\n\n<p>Python dictionaries can be a little confusing at first, but with time and effort you will be an expert in no time!<\/p>\n\n\n\n<p>As a challenge, try to declare a dictionary with the following keys and values:<\/p>\n\n\n\n<ul class=\"wp-block-list\"><li>lentil: 3.00<\/li><li>vegetable: 2.90<\/li><li>pea: 3.10<\/li><\/ul>\n\n\n\n<p>Then, use the bracket notation to print the value of &#8220;lentil&#8221; to the console. For an extra challenge, delete the value of &#8220;pea&#8221; from the dictionary. Then, print the dictionary to the console to make sure the value has been deleted.<\/p>\n\n\n\n<iframe loading=\"lazy\" src=\"https:\/\/repl.it\/@careerkarma\/PythonDictionary?lite=true\" width=\"100%\" height=\"400px\" frameborder=\"0\"><\/iframe>\n<br>\n<br>\n\n\n\n<p>To learn more about how to code in the Python programming language, check out our <a href=\"https:\/\/careerkarma.com\/blog\/how-to-learn-python\/\">How to Learn Python guide<\/a>.<\/p>\n","protected":false},"excerpt":{"rendered":"A Python dictionary stores data in key-value pairs. A key is a label for a value. Dictionaries are declared as a set of keys and values between a pair of curly brackets. The syntax for a key and value is: \"key_name\": value. When you take a look at a dictionary (Merriam-Webster\u2019s, Oxford), what do you&hellip;","protected":false},"author":77,"featured_media":12042,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[16578],"tags":[],"class_list":{"0":"post-25930","1":"post","2":"type-post","3":"status-publish","4":"format-standard","5":"has-post-thumbnail","7":"category-python"},"acf":{"post_sub_title":"","sprint_id":"","query_class":"Python","school_sft":"","parent_sft":"","school_privacy_policy":"","has_review":null,"is_sponser_post":"","is_guest_post":""},"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v27.0 (Yoast SEO v27.0) - https:\/\/yoast.com\/product\/yoast-seo-premium-wordpress\/ -->\n<title>Python Dictionary | Career Karma<\/title>\n<meta name=\"description\" content=\"Check out this resource to see how Python Dictionaries work on Career Karma!\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/careerkarma.com\/blog\/python-dictionary\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Python Dictionary: A Guide for Beginners\" \/>\n<meta property=\"og:description\" content=\"Check out this resource to see how Python Dictionaries work on Career Karma!\" \/>\n<meta property=\"og:url\" content=\"https:\/\/careerkarma.com\/blog\/python-dictionary\/\" \/>\n<meta property=\"og:site_name\" content=\"Career Karma\" \/>\n<meta property=\"article:publisher\" content=\"http:\/\/facebook.com\/careerkarmaapp\" \/>\n<meta property=\"article:published_time\" content=\"2020-12-14T01:05:30+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2022-07-20T15:35:08+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/careerkarma.com\/blog\/wp-content\/uploads\/2020\/02\/PYTHON-ARRAY.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"1000\" \/>\n\t<meta property=\"og:image:height\" content=\"668\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"Christina Kopecky\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@career_karma\" \/>\n<meta name=\"twitter:site\" content=\"@career_karma\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Christina Kopecky\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"6 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/careerkarma.com\/blog\/python-dictionary\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/careerkarma.com\/blog\/python-dictionary\/\"},\"author\":{\"name\":\"Christina Kopecky\",\"@id\":\"https:\/\/careerkarma.com\/blog\/#\/schema\/person\/ae0cdc4a5d198690d78482646894074e\"},\"headline\":\"Python Dictionary: A Guide for Beginners\",\"datePublished\":\"2020-12-14T01:05:30+00:00\",\"dateModified\":\"2022-07-20T15:35:08+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/careerkarma.com\/blog\/python-dictionary\/\"},\"wordCount\":1099,\"commentCount\":0,\"image\":{\"@id\":\"https:\/\/careerkarma.com\/blog\/python-dictionary\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/careerkarma.com\/blog\/wp-content\/uploads\/2020\/02\/PYTHON-ARRAY.jpg\",\"articleSection\":[\"Python\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/careerkarma.com\/blog\/python-dictionary\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/careerkarma.com\/blog\/python-dictionary\/\",\"url\":\"https:\/\/careerkarma.com\/blog\/python-dictionary\/\",\"name\":\"Python Dictionary | Career Karma\",\"isPartOf\":{\"@id\":\"https:\/\/careerkarma.com\/blog\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/careerkarma.com\/blog\/python-dictionary\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/careerkarma.com\/blog\/python-dictionary\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/careerkarma.com\/blog\/wp-content\/uploads\/2020\/02\/PYTHON-ARRAY.jpg\",\"datePublished\":\"2020-12-14T01:05:30+00:00\",\"dateModified\":\"2022-07-20T15:35:08+00:00\",\"author\":{\"@id\":\"https:\/\/careerkarma.com\/blog\/#\/schema\/person\/ae0cdc4a5d198690d78482646894074e\"},\"description\":\"Check out this resource to see how Python Dictionaries work on Career Karma!\",\"breadcrumb\":{\"@id\":\"https:\/\/careerkarma.com\/blog\/python-dictionary\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/careerkarma.com\/blog\/python-dictionary\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/careerkarma.com\/blog\/python-dictionary\/#primaryimage\",\"url\":\"https:\/\/careerkarma.com\/blog\/wp-content\/uploads\/2020\/02\/PYTHON-ARRAY.jpg\",\"contentUrl\":\"https:\/\/careerkarma.com\/blog\/wp-content\/uploads\/2020\/02\/PYTHON-ARRAY.jpg\",\"width\":1000,\"height\":668},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/careerkarma.com\/blog\/python-dictionary\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Blog\",\"item\":\"https:\/\/careerkarma.com\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Python\",\"item\":\"https:\/\/careerkarma.com\/blog\/python\/\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"Python Dictionary: A Guide for Beginners\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/careerkarma.com\/blog\/#website\",\"url\":\"https:\/\/careerkarma.com\/blog\/\",\"name\":\"Career Karma\",\"description\":\"Latest Coding Bootcamp News &amp; Career Hacks from Industry Insiders\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/careerkarma.com\/blog\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/careerkarma.com\/blog\/#\/schema\/person\/ae0cdc4a5d198690d78482646894074e\",\"name\":\"Christina Kopecky\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/careerkarma.com\/blog\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/careerkarma.com\/blog\/wp-content\/uploads\/2020\/06\/image-3-150x150.jpg\",\"contentUrl\":\"https:\/\/careerkarma.com\/blog\/wp-content\/uploads\/2020\/06\/image-3-150x150.jpg\",\"caption\":\"Christina Kopecky\"},\"description\":\"Christina is an experienced technical writer, covering topics as diverse as Java, SQL, Python, and web development. She earned her Master of Music in flute performance from the University of Kansas and a bachelor's degree in music with minors in French and mass communication from Southeast Missouri State. Prior to joining the Career Karma team in June 2020, Christina was a teaching assistant, team lead, and section lead at Lambda School, where she led student groups, performed code and project reviews, and debugged problems for students. Christina's technical content is featured frequently in publications like Codecademy, Repl.it, and Educative.\",\"sameAs\":[\"http:\/\/www.linkedin.com\/in\/cmvnk\"],\"url\":\"https:\/\/careerkarma.com\/blog\/author\/christina-kopecky\/\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"Python Dictionary | Career Karma","description":"Check out this resource to see how Python Dictionaries work on Career Karma!","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/careerkarma.com\/blog\/python-dictionary\/","og_locale":"en_US","og_type":"article","og_title":"Python Dictionary: A Guide for Beginners","og_description":"Check out this resource to see how Python Dictionaries work on Career Karma!","og_url":"https:\/\/careerkarma.com\/blog\/python-dictionary\/","og_site_name":"Career Karma","article_publisher":"http:\/\/facebook.com\/careerkarmaapp","article_published_time":"2020-12-14T01:05:30+00:00","article_modified_time":"2022-07-20T15:35:08+00:00","og_image":[{"width":1000,"height":668,"url":"https:\/\/careerkarma.com\/blog\/wp-content\/uploads\/2020\/02\/PYTHON-ARRAY.jpg","type":"image\/jpeg"}],"author":"Christina Kopecky","twitter_card":"summary_large_image","twitter_creator":"@career_karma","twitter_site":"@career_karma","twitter_misc":{"Written by":"Christina Kopecky","Est. reading time":"6 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/careerkarma.com\/blog\/python-dictionary\/#article","isPartOf":{"@id":"https:\/\/careerkarma.com\/blog\/python-dictionary\/"},"author":{"name":"Christina Kopecky","@id":"https:\/\/careerkarma.com\/blog\/#\/schema\/person\/ae0cdc4a5d198690d78482646894074e"},"headline":"Python Dictionary: A Guide for Beginners","datePublished":"2020-12-14T01:05:30+00:00","dateModified":"2022-07-20T15:35:08+00:00","mainEntityOfPage":{"@id":"https:\/\/careerkarma.com\/blog\/python-dictionary\/"},"wordCount":1099,"commentCount":0,"image":{"@id":"https:\/\/careerkarma.com\/blog\/python-dictionary\/#primaryimage"},"thumbnailUrl":"https:\/\/careerkarma.com\/blog\/wp-content\/uploads\/2020\/02\/PYTHON-ARRAY.jpg","articleSection":["Python"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/careerkarma.com\/blog\/python-dictionary\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/careerkarma.com\/blog\/python-dictionary\/","url":"https:\/\/careerkarma.com\/blog\/python-dictionary\/","name":"Python Dictionary | Career Karma","isPartOf":{"@id":"https:\/\/careerkarma.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/careerkarma.com\/blog\/python-dictionary\/#primaryimage"},"image":{"@id":"https:\/\/careerkarma.com\/blog\/python-dictionary\/#primaryimage"},"thumbnailUrl":"https:\/\/careerkarma.com\/blog\/wp-content\/uploads\/2020\/02\/PYTHON-ARRAY.jpg","datePublished":"2020-12-14T01:05:30+00:00","dateModified":"2022-07-20T15:35:08+00:00","author":{"@id":"https:\/\/careerkarma.com\/blog\/#\/schema\/person\/ae0cdc4a5d198690d78482646894074e"},"description":"Check out this resource to see how Python Dictionaries work on Career Karma!","breadcrumb":{"@id":"https:\/\/careerkarma.com\/blog\/python-dictionary\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/careerkarma.com\/blog\/python-dictionary\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/careerkarma.com\/blog\/python-dictionary\/#primaryimage","url":"https:\/\/careerkarma.com\/blog\/wp-content\/uploads\/2020\/02\/PYTHON-ARRAY.jpg","contentUrl":"https:\/\/careerkarma.com\/blog\/wp-content\/uploads\/2020\/02\/PYTHON-ARRAY.jpg","width":1000,"height":668},{"@type":"BreadcrumbList","@id":"https:\/\/careerkarma.com\/blog\/python-dictionary\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Blog","item":"https:\/\/careerkarma.com\/blog\/"},{"@type":"ListItem","position":2,"name":"Python","item":"https:\/\/careerkarma.com\/blog\/python\/"},{"@type":"ListItem","position":3,"name":"Python Dictionary: A Guide for Beginners"}]},{"@type":"WebSite","@id":"https:\/\/careerkarma.com\/blog\/#website","url":"https:\/\/careerkarma.com\/blog\/","name":"Career Karma","description":"Latest Coding Bootcamp News &amp; Career Hacks from Industry Insiders","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/careerkarma.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/careerkarma.com\/blog\/#\/schema\/person\/ae0cdc4a5d198690d78482646894074e","name":"Christina Kopecky","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/careerkarma.com\/blog\/#\/schema\/person\/image\/","url":"https:\/\/careerkarma.com\/blog\/wp-content\/uploads\/2020\/06\/image-3-150x150.jpg","contentUrl":"https:\/\/careerkarma.com\/blog\/wp-content\/uploads\/2020\/06\/image-3-150x150.jpg","caption":"Christina Kopecky"},"description":"Christina is an experienced technical writer, covering topics as diverse as Java, SQL, Python, and web development. She earned her Master of Music in flute performance from the University of Kansas and a bachelor's degree in music with minors in French and mass communication from Southeast Missouri State. Prior to joining the Career Karma team in June 2020, Christina was a teaching assistant, team lead, and section lead at Lambda School, where she led student groups, performed code and project reviews, and debugged problems for students. Christina's technical content is featured frequently in publications like Codecademy, Repl.it, and Educative.","sameAs":["http:\/\/www.linkedin.com\/in\/cmvnk"],"url":"https:\/\/careerkarma.com\/blog\/author\/christina-kopecky\/"}]}},"_links":{"self":[{"href":"https:\/\/careerkarma.com\/blog\/wp-json\/wp\/v2\/posts\/25930","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/careerkarma.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/careerkarma.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/careerkarma.com\/blog\/wp-json\/wp\/v2\/users\/77"}],"replies":[{"embeddable":true,"href":"https:\/\/careerkarma.com\/blog\/wp-json\/wp\/v2\/comments?post=25930"}],"version-history":[{"count":0,"href":"https:\/\/careerkarma.com\/blog\/wp-json\/wp\/v2\/posts\/25930\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/careerkarma.com\/blog\/wp-json\/wp\/v2\/media\/12042"}],"wp:attachment":[{"href":"https:\/\/careerkarma.com\/blog\/wp-json\/wp\/v2\/media?parent=25930"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/careerkarma.com\/blog\/wp-json\/wp\/v2\/categories?post=25930"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/careerkarma.com\/blog\/wp-json\/wp\/v2\/tags?post=25930"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}