{"id":37586,"date":"2016-09-11T22:24:07","date_gmt":"2016-09-12T03:24:07","guid":{"rendered":"http:\/\/rodrigomerinos.wordpress.com\/?p=90"},"modified":"2016-09-11T22:24:07","modified_gmt":"2016-09-12T03:24:07","slug":"youre-not-my-type-sorry","status":"publish","type":"post","link":"https:\/\/kenscourses.com\/tc101fall2016\/syndicated\/youre-not-my-type-sorry\/","title":{"rendered":"You\u2019re not my Type sorry"},"content":{"rendered":"<p class=\"syndicated-attribution\"><em> --Originally published at <a href=\"https:\/\/rodrigomerinos.wordpress.com\/2016\/09\/11\/youre-not-my-type-sorry\/\"><a href=\"https:\/\/rodrigomerinos.wordpress.com\">M E R I N O<\/a><\/a><\/em><br \/><\/p>\n<p><strong>Variables:<\/strong><\/p>\n<p>First, we have to know what is a variable?<\/p>\n<blockquote><p><em>In programming, a variable is a value that can change, depending on conditions or on information passed to the program<\/em><\/p>\n<p><a href=\"http:\/\/whatis.techtarget.com\/definition\/variable\">-WhatIs.com<\/a><\/p><\/blockquote>\n<p>Now, we know what is a variable but&#8230; <strong>How do I assign it?<\/strong><\/p>\n<p>To assign a variable you just need to add the equal sign (=) that&#8217;s it, you now have a variable&#8230; Kinda.<\/p>\n<p>Also you can do multiples assignments like this:<\/p>\n<p>Or assign the same value to different variables like this:<\/p>\n<p>&nbsp;<\/p>\n<p><strong>Types of variables:<\/strong><\/p>\n<p>There are 6 main datatypes of variables.<\/p>\n<p><strong>1- Numbers:<\/strong><\/p>\n<p>In this category are 4 &#8220;subcategories&#8221;:<\/p>\n<ul>\n<li>Integers (int)<\/li>\n<li>Long Integers (long)<\/li>\n<li>Floating point real values (float)<\/li>\n<li>Complex Numbers (complex)<\/li>\n<\/ul>\n<p>Here are some examples:<\/p>\n<p><img class=\" size-full wp-image-228 aligncenter\" src=\"https:\/\/rodrigomerinos.files.wordpress.com\/2016\/09\/captura-de-pantalla-2016-09-11-a-las-20-37-28.png?w=736\" alt=\"captura-de-pantalla-2016-09-11-a-las-20-37-28\"   \/><\/p>\n<p><strong><img class=\" size-full wp-image-229 aligncenter\" src=\"https:\/\/rodrigomerinos.files.wordpress.com\/2016\/09\/captura-de-pantalla-2016-09-11-a-las-20-38-17.png?w=736\" alt=\"captura-de-pantalla-2016-09-11-a-las-20-38-17\"   \/><\/strong><\/p>\n<p><strong>2 -String:<\/strong><\/p>\n<p>In a string variable you can add any type of characters, number, symbols letters, you only need to add &#8220;&#8221; and write whatever you want, like this.<img class=\" size-full wp-image-234 aligncenter\" src=\"https:\/\/rodrigomerinos.files.wordpress.com\/2016\/09\/captura-de-pantalla-2016-09-11-a-las-20-40-43.png?w=736\" alt=\"Captura de pantalla 2016-09-11 a la(s) 20.40.43.png\"   \/><\/p>\n<p>&nbsp;<\/p>\n<p><strong>3- List:<\/strong><\/p>\n<p>In this variable you can add various values to a single variable, you declare it with [] and separate the values with a &#8221; , &#8221; like this<img class=\" size-full wp-image-239 aligncenter\" src=\"https:\/\/rodrigomerinos.files.wordpress.com\/2016\/09\/captura-de-pantalla-2016-09-11-a-las-20-49-27.png?w=736\" alt=\"Captura de pantalla 2016-09-11 a la(s) 20.49.27.png\"   \/><img class=\" size-full wp-image-242 aligncenter\" src=\"https:\/\/rodrigomerinos.files.wordpress.com\/2016\/09\/captura-de-pantalla-2016-09-11-a-las-20-50-01.png?w=736\" alt=\"Captura de pantalla 2016-09-11 a la(s) 20.50.01.png\"   \/><\/p>\n<p>Then you can choose the value you want or\u00a0the range of values. For a single value you only write between the [] the number in which the value is positioned, be careful because in Python, the first value is the value 0<\/p>\n<p><img class=\"alignnone size-full wp-image-246\" src=\"https:\/\/rodrigomerinos.files.wordpress.com\/2016\/09\/captura-de-pantalla-2016-09-11-a-las-20-50-41.png?w=736\" alt=\"Captura de pantalla 2016-09-11 a la(s) 20.50.41.png\"   \/><img class=\"alignnone size-full wp-image-248\" src=\"https:\/\/rodrigomerinos.files.wordpress.com\/2016\/09\/captura-de-pantalla-2016-09-11-a-las-20-51-09.png?w=736\" alt=\"Captura de pantalla 2016-09-11 a la(s) 20.51.09.png\"   \/><\/p>\n<p><img class=\"alignnone size-full wp-image-250\" src=\"https:\/\/rodrigomerinos.files.wordpress.com\/2016\/09\/captura-de-pantalla-2016-09-11-a-las-21-03-25.png?w=736\" alt=\"Captura de pantalla 2016-09-11 a la(s) 21.03.25.png\"   \/><img class=\"alignnone size-full wp-image-252\" src=\"https:\/\/rodrigomerinos.files.wordpress.com\/2016\/09\/captura-de-pantalla-2016-09-11-a-las-21-03-42.png?w=736\" alt=\"Captura de pantalla 2016-09-11 a la(s) 21.03.42.png\"   \/><\/p>\n<p>To remove an element from the list, you can use\u00a0<em>del list [#]\u00a0<\/em> or you can use <em>list.<\/em><em>remove (&#8220;value&#8221;)<\/em>. It only takes out the value but the sequence keeps going with the next value . Here is an example:<\/p>\n<p><img class=\" size-full wp-image-255 aligncenter\" src=\"https:\/\/rodrigomerinos.files.wordpress.com\/2016\/09\/captura-de-pantalla-2016-09-11-a-las-21-07-45.png?w=736\" alt=\"Captura de pantalla 2016-09-11 a la(s) 21.07.45.png\"   \/><br \/>\n<img class=\" size-full wp-image-256 aligncenter\" src=\"https:\/\/rodrigomerinos.files.wordpress.com\/2016\/09\/captura-de-pantalla-2016-09-11-a-las-21-08-02.png?w=736\" alt=\"Captura de pantalla 2016-09-11 a la(s) 21.08.02.png\"   \/><\/p>\n<p>Also you can change or update the values of a list, like this:<br \/>\n<img class=\" size-full wp-image-286 aligncenter\" src=\"https:\/\/rodrigomerinos.files.wordpress.com\/2016\/09\/captura-de-pantalla-2016-09-11-a-las-22-16-10.png?w=736\" alt=\"Captura de pantalla 2016-09-11 a la(s) 22.16.10.png\"   \/><\/p>\n<p><strong><img class=\" size-full wp-image-288 aligncenter\" src=\"https:\/\/rodrigomerinos.files.wordpress.com\/2016\/09\/captura-de-pantalla-2016-09-11-a-las-22-16-35.png?w=736\" alt=\"Captura de pantalla 2016-09-11 a la(s) 22.16.35.png\"   \/><\/strong><\/p>\n<p><strong>4 &#8211; Tuple:<\/strong><\/p>\n<p>A Tuple is like a list, but less flexible and instead of using [] we use (). You can&#8217;t replace values. Example:<img class=\" size-full wp-image-267 aligncenter\" src=\"https:\/\/rodrigomerinos.files.wordpress.com\/2016\/09\/captura-de-pantalla-2016-09-11-a-las-22-04-52.png?w=736\" alt=\"Captura de pantalla 2016-09-11 a la(s) 22.04.52.png\"   \/><\/p>\n<p><strong><img class=\" size-full wp-image-268 aligncenter\" src=\"https:\/\/rodrigomerinos.files.wordpress.com\/2016\/09\/captura-de-pantalla-2016-09-11-a-las-22-05-33.png?w=736\" alt=\"Captura de pantalla 2016-09-11 a la(s) 22.05.33.png\"   \/>5- <div class=\"post-limited-image\"><img class=\" size-full wp-image-276 aligncenter\" src=\"https:\/\/rodrigomerinos.files.wordpress.com\/2016\/09\/captura-de-pantalla-2016-09-11-a-las-22-11-10.png?w=736\" alt=\"Captura de pantalla 2016-09-11 a la(s) 22.11.10.png\"   \/><\/div>\n<div class=\"post-limited-image\"><img class=\" size-full wp-image-278 aligncenter\" src=\"https:\/\/rodrigomerinos.files.wordpress.com\/2016\/09\/captura-de-pantalla-2016-09-11-a-las-22-11-23.png?w=736\" alt=\"Captura de pantalla 2016-09-11 a la(s) 22.11.23.png\"   \/><\/div>\n<div class=\"post-limited-image\"><img class=\" size-full wp-image-296 aligncenter\" src=\"https:\/\/rodrigomerinos.files.wordpress.com\/2016\/09\/captura-de-pantalla-2016-09-11-a-las-22-21-35.png?w=736\" alt=\"Captura de pantalla 2016-09-11 a la(s) 22.21.35.png\"   \/><\/div>\n<div class=\"post-limited-image\"><img class=\" size-full wp-image-298 aligncenter\" src=\"https:\/\/rodrigomerinos.files.wordpress.com\/2016\/09\/captura-de-pantalla-2016-09-11-a-las-22-21-56.png?w=736\" alt=\"Captura de pantalla 2016-09-11 a la(s) 22.21.56.png\"   \/><\/div>\n<div class=\"post-limited-image\"><img alt=\"\" border=\"0\" src=\"http:\/\/feeds.wordpress.com\/1.0\/comments\/rodrigomerinos.wordpress.com\/90\/\" \/><\/div>\n<div class=\"post-limited-image\"><img alt=\"\" border=\"0\" src=\"https:\/\/pixel.wp.com\/b.gif?host=rodrigomerinos.wordpress.com&#038;blog=115217129&%23038;post=90&%23038;subd=rodrigomerinos&%23038;ref=&%23038;feed=1\" width=\"1\" height=\"1\" \/><\/div><!--more--><\/strong><\/p>\n<p>Set is also like a list, but there is no order, you cannot call a certain value of the Set and you can only write unique values. To declare a Set we use {}. If you look closely , in the code are 2 &#8220;3&#8221; and in the final program it only shows 1.<\/p>\n<p><img class=\" size-full wp-image-276 aligncenter\" src=\"https:\/\/rodrigomerinos.files.wordpress.com\/2016\/09\/captura-de-pantalla-2016-09-11-a-las-22-11-10.png?w=736\" alt=\"Captura de pantalla 2016-09-11 a la(s) 22.11.10.png\"   \/><\/p>\n<p><img class=\" size-full wp-image-278 aligncenter\" src=\"https:\/\/rodrigomerinos.files.wordpress.com\/2016\/09\/captura-de-pantalla-2016-09-11-a-las-22-11-23.png?w=736\" alt=\"Captura de pantalla 2016-09-11 a la(s) 22.11.23.png\"   \/><\/p>\n<p><strong>6- Dictionary:<\/strong><\/p>\n<p>A Dictionary\u00a0is often used when you have a lot of data. You assign a keyword to a value.<br \/>\n<em>dic = {&#8220;key&#8221;:&#8221;value&#8221;, &#8220;key2&#8243;:&#8221;value2&#8221;}<\/em>\u00a0.Like this:<\/p>\n<p><img class=\" size-full wp-image-296 aligncenter\" src=\"https:\/\/rodrigomerinos.files.wordpress.com\/2016\/09\/captura-de-pantalla-2016-09-11-a-las-22-21-35.png?w=736\" alt=\"Captura de pantalla 2016-09-11 a la(s) 22.21.35.png\"   \/><\/p>\n<p><img class=\" size-full wp-image-298 aligncenter\" src=\"https:\/\/rodrigomerinos.files.wordpress.com\/2016\/09\/captura-de-pantalla-2016-09-11-a-las-22-21-56.png?w=736\" alt=\"Captura de pantalla 2016-09-11 a la(s) 22.21.56.png\"   \/><\/p>\n<p>If you want to learn more you can click <a href=\"https:\/\/www.tutorialspoint.com\/\">here<\/a>. Thanks for reading.<\/p><br \/>  <a rel=\"nofollow\" href=\"http:\/\/feeds.wordpress.com\/1.0\/gocomments\/rodrigomerinos.wordpress.com\/90\/\"><img alt=\"\" border=\"0\" src=\"http:\/\/feeds.wordpress.com\/1.0\/comments\/rodrigomerinos.wordpress.com\/90\/\" \/><\/a> <img alt=\"\" border=\"0\" src=\"https:\/\/pixel.wp.com\/b.gif?host=rodrigomerinos.wordpress.com&#038;blog=115217129&%23038;post=90&%23038;subd=rodrigomerinos&%23038;ref=&%23038;feed=1\" width=\"1\" height=\"1\" \/>","protected":false},"excerpt":{"rendered":"<p>&#8211;Originally published at M E R I N O Variables: First, we have to know what is a variable? In programming, a variable is a value that can change, depending on conditions or on information passed to the program -WhatIs.com Now, we know what is a variable but&#8230; How do I assign it? To assign &hellip; <a href=\"https:\/\/kenscourses.com\/tc101fall2016\/syndicated\/youre-not-my-type-sorry\/\" class=\"more-link\">Continue reading <span class=\"screen-reader-text\">You\u2019re not my Type sorry<\/span><\/a><\/p>\n","protected":false},"author":46,"featured_media":228,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[5,4],"tags":[124,24],"class_list":["post-37586","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-blogs","category-syndicated","tag-code","tag-python"],"_links":{"self":[{"href":"https:\/\/kenscourses.com\/tc101fall2016\/wp-json\/wp\/v2\/posts\/37586","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/kenscourses.com\/tc101fall2016\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/kenscourses.com\/tc101fall2016\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/kenscourses.com\/tc101fall2016\/wp-json\/wp\/v2\/users\/46"}],"replies":[{"embeddable":true,"href":"https:\/\/kenscourses.com\/tc101fall2016\/wp-json\/wp\/v2\/comments?post=37586"}],"version-history":[{"count":4,"href":"https:\/\/kenscourses.com\/tc101fall2016\/wp-json\/wp\/v2\/posts\/37586\/revisions"}],"predecessor-version":[{"id":38672,"href":"https:\/\/kenscourses.com\/tc101fall2016\/wp-json\/wp\/v2\/posts\/37586\/revisions\/38672"}],"wp:attachment":[{"href":"https:\/\/kenscourses.com\/tc101fall2016\/wp-json\/wp\/v2\/media?parent=37586"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/kenscourses.com\/tc101fall2016\/wp-json\/wp\/v2\/categories?post=37586"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/kenscourses.com\/tc101fall2016\/wp-json\/wp\/v2\/tags?post=37586"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}