[{"data":1,"prerenderedAt":2322},["ShallowReactive",2],{"doc-\u002Flearn\u002Fpython-data-types-overview":3},{"id":4,"title":5,"body":6,"description":2315,"extension":2316,"meta":2317,"navigation":93,"path":2318,"seo":2319,"stem":2320,"__hash__":2321},"content\u002Flearn\u002Fpython-data-types-overview.md","Python Data Types Overview",{"type":7,"value":8,"toc":2282},"minimark",[9,13,22,25,30,38,179,182,238,241,245,261,265,272,275,295,298,309,312,316,319,322,344,347,356,359,388,390,399,402,425,432,435,446,454,458,461,466,472,475,491,545,550,555,557,574,632,639,643,648,651,667,730,733,767,774,779,784,796,799,855,862,866,869,873,878,935,937,964,967,975,982,987,992,1041,1044,1049,1054,1097,1100,1122,1125,1130,1138,1216,1218,1227,1234,1238,1244,1319,1322,1333,1340,1400,1402,1417,1423,1427,1430,1462,1464,1597,1600,1617,1621,1624,1641,1644,1712,1714,1738,1745,1806,1809,1840,1845,1857,1861,1864,1889,1891,1953,1955,1988,1992,1995,2012,2015,2095,2098,2130,2133,2147,2151,2154,2157,2172,2175,2179,2183,2186,2190,2202,2206,2227,2234,2244,2248,2251,2255,2278],[10,11,5],"h1",{"id":12},"python-data-types-overview",[14,15,16,17,21],"p",{},"Python has different ",[18,19,20],"strong",{},"data types"," for different kinds of values.",[14,23,24],{},"This beginner-friendly overview explains what data types are, why they matter, and how to recognize the most common built-in types. You do not need to memorize everything at once. The goal is to understand the basic idea and know which types you will use most often.",[26,27,29],"h2",{"id":28},"quick-way-to-check-a-type","Quick way to check a type",[14,31,32,33,37],{},"Use ",[34,35,36],"code",{},"type()"," to quickly check what kind of value you are working with.",[39,40,45],"pre",{"className":41,"code":42,"language":43,"meta":44,"style":44},"language-python shiki shiki-themes material-theme-lighter github-light github-dark","x = 10\nprint(type(x))\n\ny = \"hello\"\nprint(type(y))\n\nz = [1, 2, 3]\nprint(type(z))\n","python","",[34,46,47,64,88,95,114,130,135,163],{"__ignoreMap":44},[48,49,52,56,60],"span",{"class":50,"line":51},"line",1,[48,53,55],{"class":54},"su5hD","x ",[48,57,59],{"class":58},"smGrS","=",[48,61,63],{"class":62},"srdBf"," 10\n",[48,65,67,71,75,79,81,85],{"class":50,"line":66},2,[48,68,70],{"class":69},"sptTA","print",[48,72,74],{"class":73},"sP7_E","(",[48,76,78],{"class":77},"sZMiF","type",[48,80,74],{"class":73},[48,82,84],{"class":83},"slqww","x",[48,86,87],{"class":73},"))\n",[48,89,91],{"class":50,"line":90},3,[48,92,94],{"emptyLinePlaceholder":93},true,"\n",[48,96,98,101,103,107,111],{"class":50,"line":97},4,[48,99,100],{"class":54},"y ",[48,102,59],{"class":58},[48,104,106],{"class":105},"sjJ54"," \"",[48,108,110],{"class":109},"s_sjI","hello",[48,112,113],{"class":105},"\"\n",[48,115,117,119,121,123,125,128],{"class":50,"line":116},5,[48,118,70],{"class":69},[48,120,74],{"class":73},[48,122,78],{"class":77},[48,124,74],{"class":73},[48,126,127],{"class":83},"y",[48,129,87],{"class":73},[48,131,133],{"class":50,"line":132},6,[48,134,94],{"emptyLinePlaceholder":93},[48,136,138,141,143,146,149,152,155,157,160],{"class":50,"line":137},7,[48,139,140],{"class":54},"z ",[48,142,59],{"class":58},[48,144,145],{"class":73}," [",[48,147,148],{"class":62},"1",[48,150,151],{"class":73},",",[48,153,154],{"class":62}," 2",[48,156,151],{"class":73},[48,158,159],{"class":62}," 3",[48,161,162],{"class":73},"]\n",[48,164,166,168,170,172,174,177],{"class":50,"line":165},8,[48,167,70],{"class":69},[48,169,74],{"class":73},[48,171,78],{"class":77},[48,173,74],{"class":73},[48,175,176],{"class":83},"z",[48,178,87],{"class":73},[14,180,181],{},"Expected output:",[39,183,185],{"className":41,"code":184,"language":43,"meta":44,"style":44},"\u003Cclass 'int'>\n\u003Cclass 'str'>\n\u003Cclass 'list'>\n",[34,186,187,208,223],{"__ignoreMap":44},[48,188,189,192,196,199,202,205],{"class":50,"line":51},[48,190,191],{"class":58},"\u003C",[48,193,195],{"class":194},"sbsja","class",[48,197,198],{"class":105}," '",[48,200,201],{"class":109},"int",[48,203,204],{"class":105},"'",[48,206,207],{"class":58},">\n",[48,209,210,212,214,216,219,221],{"class":50,"line":66},[48,211,191],{"class":58},[48,213,195],{"class":194},[48,215,198],{"class":105},[48,217,218],{"class":109},"str",[48,220,204],{"class":105},[48,222,207],{"class":58},[48,224,225,227,229,231,234,236],{"class":50,"line":90},[48,226,191],{"class":58},[48,228,195],{"class":194},[48,230,198],{"class":105},[48,232,233],{"class":109},"list",[48,235,204],{"class":105},[48,237,207],{"class":58},[14,239,240],{},"This is a useful first step when a program is not behaving the way you expect.",[26,242,244],{"id":243},"what-this-page-covers","What this page covers",[246,247,248,252,255,258],"ul",{},[249,250,251],"li",{},"Explain what a data type is",[249,253,254],{},"Show the main built-in Python data types beginners use first",[249,256,257],{},"Help you choose the right type for simple tasks",[249,259,260],{},"Keep details light and point you to focused pages for each type",[26,262,264],{"id":263},"what-a-data-type-means","What a data type means",[14,266,267,268,271],{},"A ",[18,269,270],{},"data type"," tells Python what kind of value something is.",[14,273,274],{},"For example:",[246,276,277,283,289],{},[249,278,279,282],{},[34,280,281],{},"10"," is a number",[249,284,285,288],{},[34,286,287],{},"\"hello\""," is text",[249,290,291,294],{},[34,292,293],{},"[1, 2, 3]"," is a collection of values",[14,296,297],{},"The type matters because it affects what you can do with the value.",[246,299,300,303,306],{},[249,301,302],{},"You can add numbers",[249,304,305],{},"You can join strings",[249,307,308],{},"You can store many items in a list",[14,310,311],{},"Using the right type helps you write correct code and avoid common errors.",[26,313,315],{"id":314},"why-data-types-matter","Why data types matter",[14,317,318],{},"Different types behave differently.",[14,320,321],{},"For example, this works because both values are numbers:",[39,323,325],{"className":41,"code":324,"language":43,"meta":44,"style":44},"print(2 + 3)\n",[34,326,327],{"__ignoreMap":44},[48,328,329,331,333,336,339,341],{"class":50,"line":51},[48,330,70],{"class":69},[48,332,74],{"class":73},[48,334,335],{"class":62},"2",[48,337,338],{"class":58}," +",[48,340,159],{"class":62},[48,342,343],{"class":73},")\n",[14,345,346],{},"Output:",[39,348,350],{"className":41,"code":349,"language":43,"meta":44,"style":44},"5\n",[34,351,352],{"__ignoreMap":44},[48,353,354],{"class":50,"line":51},[48,355,349],{"class":62},[14,357,358],{},"But this does something different because both values are strings:",[39,360,362],{"className":41,"code":361,"language":43,"meta":44,"style":44},"print(\"2\" + \"3\")\n",[34,363,364],{"__ignoreMap":44},[48,365,366,368,370,373,375,377,379,381,384,386],{"class":50,"line":51},[48,367,70],{"class":69},[48,369,74],{"class":73},[48,371,372],{"class":105},"\"",[48,374,335],{"class":109},[48,376,372],{"class":105},[48,378,338],{"class":58},[48,380,106],{"class":105},[48,382,383],{"class":109},"3",[48,385,372],{"class":105},[48,387,343],{"class":73},[14,389,346],{},[39,391,393],{"className":41,"code":392,"language":43,"meta":44,"style":44},"23\n",[34,394,395],{"__ignoreMap":44},[48,396,397],{"class":50,"line":51},[48,398,392],{"class":62},[14,400,401],{},"And this causes an error because Python does not automatically combine a string and an integer in this way:",[39,403,405],{"className":41,"code":404,"language":43,"meta":44,"style":44},"print(\"2\" + 3)\n",[34,406,407],{"__ignoreMap":44},[48,408,409,411,413,415,417,419,421,423],{"class":50,"line":51},[48,410,70],{"class":69},[48,412,74],{"class":73},[48,414,372],{"class":105},[48,416,335],{"class":109},[48,418,372],{"class":105},[48,420,338],{"class":58},[48,422,159],{"class":62},[48,424,343],{"class":73},[14,426,427,428,431],{},"This raises a ",[34,429,430],{},"TypeError",".",[14,433,434],{},"Knowing the type of a value helps you:",[246,436,437,440,443],{},[249,438,439],{},"understand what operations are allowed",[249,441,442],{},"use functions correctly",[249,444,445],{},"debug problems faster",[14,447,448,449,431],{},"If you are new to variables, see ",[450,451,453],"a",{"href":452},"\u002Flearn\u002Fpython-variables-explained-for-beginners\u002F","Python variables explained for beginners",[26,455,457],{"id":456},"main-simple-data-types","Main simple data types",[14,459,460],{},"These are the first built-in types most beginners use.",[462,463,464],"h3",{"id":201},[34,465,201],{},[14,467,468,469,471],{},"An ",[34,470,201],{}," is a whole number.",[14,473,474],{},"Examples:",[246,476,477,481,486],{},[249,478,479],{},[34,480,148],{},[249,482,483],{},[34,484,485],{},"20",[249,487,488],{},[34,489,490],{},"-5",[39,492,494],{"className":41,"code":493,"language":43,"meta":44,"style":44},"age = 25\ncount = 10\n\nprint(age)\nprint(type(count))\n",[34,495,496,506,515,519,530],{"__ignoreMap":44},[48,497,498,501,503],{"class":50,"line":51},[48,499,500],{"class":54},"age ",[48,502,59],{"class":58},[48,504,505],{"class":62}," 25\n",[48,507,508,511,513],{"class":50,"line":66},[48,509,510],{"class":54},"count ",[48,512,59],{"class":58},[48,514,63],{"class":62},[48,516,517],{"class":50,"line":90},[48,518,94],{"emptyLinePlaceholder":93},[48,520,521,523,525,528],{"class":50,"line":97},[48,522,70],{"class":69},[48,524,74],{"class":73},[48,526,527],{"class":83},"age",[48,529,343],{"class":73},[48,531,532,534,536,538,540,543],{"class":50,"line":116},[48,533,70],{"class":69},[48,535,74],{"class":73},[48,537,78],{"class":77},[48,539,74],{"class":73},[48,541,542],{"class":83},"count",[48,544,87],{"class":73},[462,546,548],{"id":547},"float",[34,549,547],{},[14,551,267,552,554],{},[34,553,547],{}," is a number with a decimal point.",[14,556,474],{},[246,558,559,564,569],{},[249,560,561],{},[34,562,563],{},"3.14",[249,565,566],{},[34,567,568],{},"0.5",[249,570,571],{},[34,572,573],{},"-2.75",[39,575,577],{"className":41,"code":576,"language":43,"meta":44,"style":44},"price = 19.99\ntemperature = -0.5\n\nprint(price)\nprint(type(temperature))\n",[34,578,579,589,602,606,617],{"__ignoreMap":44},[48,580,581,584,586],{"class":50,"line":51},[48,582,583],{"class":54},"price ",[48,585,59],{"class":58},[48,587,588],{"class":62}," 19.99\n",[48,590,591,594,596,599],{"class":50,"line":66},[48,592,593],{"class":54},"temperature ",[48,595,59],{"class":58},[48,597,598],{"class":58}," -",[48,600,601],{"class":62},"0.5\n",[48,603,604],{"class":50,"line":90},[48,605,94],{"emptyLinePlaceholder":93},[48,607,608,610,612,615],{"class":50,"line":97},[48,609,70],{"class":69},[48,611,74],{"class":73},[48,613,614],{"class":83},"price",[48,616,343],{"class":73},[48,618,619,621,623,625,627,630],{"class":50,"line":116},[48,620,70],{"class":69},[48,622,74],{"class":73},[48,624,78],{"class":77},[48,626,74],{"class":73},[48,628,629],{"class":83},"temperature",[48,631,87],{"class":73},[14,633,634,635,431],{},"For a focused guide, read ",[450,636,638],{"href":637},"\u002Flearn\u002Fpython-numbers-explained-int-float-complex\u002F","Python numbers explained: int and float",[462,640,641],{"id":218},[34,642,218],{},[14,644,267,645,647],{},[34,646,218],{}," is a text value.",[14,649,650],{},"Strings go inside quotes:",[246,652,653,657,662],{},[249,654,655],{},[34,656,287],{},[249,658,659],{},[34,660,661],{},"'Python'",[249,663,664],{},[34,665,666],{},"\"123\"",[39,668,670],{"className":41,"code":669,"language":43,"meta":44,"style":44},"name = \"Ava\"\nmessage = \"Hello\"\n\nprint(name)\nprint(type(message))\n",[34,671,672,686,700,704,715],{"__ignoreMap":44},[48,673,674,677,679,681,684],{"class":50,"line":51},[48,675,676],{"class":54},"name ",[48,678,59],{"class":58},[48,680,106],{"class":105},[48,682,683],{"class":109},"Ava",[48,685,113],{"class":105},[48,687,688,691,693,695,698],{"class":50,"line":66},[48,689,690],{"class":54},"message ",[48,692,59],{"class":58},[48,694,106],{"class":105},[48,696,697],{"class":109},"Hello",[48,699,113],{"class":105},[48,701,702],{"class":50,"line":90},[48,703,94],{"emptyLinePlaceholder":93},[48,705,706,708,710,713],{"class":50,"line":97},[48,707,70],{"class":69},[48,709,74],{"class":73},[48,711,712],{"class":83},"name",[48,714,343],{"class":73},[48,716,717,719,721,723,725,728],{"class":50,"line":116},[48,718,70],{"class":69},[48,720,74],{"class":73},[48,722,78],{"class":77},[48,724,74],{"class":73},[48,726,727],{"class":83},"message",[48,729,87],{"class":73},[14,731,732],{},"Even if a string looks like a number, it is still text:",[39,734,736],{"className":41,"code":735,"language":43,"meta":44,"style":44},"value = \"123\"\nprint(type(value))\n",[34,737,738,752],{"__ignoreMap":44},[48,739,740,743,745,747,750],{"class":50,"line":51},[48,741,742],{"class":54},"value ",[48,744,59],{"class":58},[48,746,106],{"class":105},[48,748,749],{"class":109},"123",[48,751,113],{"class":105},[48,753,754,756,758,760,762,765],{"class":50,"line":66},[48,755,70],{"class":69},[48,757,74],{"class":73},[48,759,78],{"class":77},[48,761,74],{"class":73},[48,763,764],{"class":83},"value",[48,766,87],{"class":73},[14,768,769,770,431],{},"To learn more, see ",[450,771,773],{"href":772},"\u002Flearn\u002Fpython-strings-explained-basics-and-examples\u002F","Python strings explained: basics and examples",[462,775,777],{"id":776},"bool",[34,778,776],{},[14,780,267,781,783],{},[34,782,776],{}," has only two possible values:",[246,785,786,791],{},[249,787,788],{},[34,789,790],{},"True",[249,792,793],{},[34,794,795],{},"False",[14,797,798],{},"Booleans are often used in comparisons and conditions.",[39,800,802],{"className":41,"code":801,"language":43,"meta":44,"style":44},"is_logged_in = True\nis_admin = False\n\nprint(is_logged_in)\nprint(type(is_admin))\n",[34,803,804,815,825,829,840],{"__ignoreMap":44},[48,805,806,809,811],{"class":50,"line":51},[48,807,808],{"class":54},"is_logged_in ",[48,810,59],{"class":58},[48,812,814],{"class":813},"s39Yj"," True\n",[48,816,817,820,822],{"class":50,"line":66},[48,818,819],{"class":54},"is_admin ",[48,821,59],{"class":58},[48,823,824],{"class":813}," False\n",[48,826,827],{"class":50,"line":90},[48,828,94],{"emptyLinePlaceholder":93},[48,830,831,833,835,838],{"class":50,"line":97},[48,832,70],{"class":69},[48,834,74],{"class":73},[48,836,837],{"class":83},"is_logged_in",[48,839,343],{"class":73},[48,841,842,844,846,848,850,853],{"class":50,"line":116},[48,843,70],{"class":69},[48,845,74],{"class":73},[48,847,78],{"class":77},[48,849,74],{"class":73},[48,851,852],{"class":83},"is_admin",[48,854,87],{"class":73},[14,856,857,858,431],{},"For more detail, see ",[450,859,861],{"href":860},"\u002Flearn\u002Fpython-booleans-explained-true-and-false\u002F","Python booleans explained: True and False",[26,863,865],{"id":864},"main-collection-data-types","Main collection data types",[14,867,868],{},"Collection types store multiple values.",[462,870,871],{"id":233},[34,872,233],{},[14,874,267,875,877],{},[34,876,233],{}," is an ordered, changeable collection.",[39,879,881],{"className":41,"code":880,"language":43,"meta":44,"style":44},"numbers = [1, 2, 3]\nnumbers.append(4)\n\nprint(numbers)\n",[34,882,883,904,921,925],{"__ignoreMap":44},[48,884,885,888,890,892,894,896,898,900,902],{"class":50,"line":51},[48,886,887],{"class":54},"numbers ",[48,889,59],{"class":58},[48,891,145],{"class":73},[48,893,148],{"class":62},[48,895,151],{"class":73},[48,897,154],{"class":62},[48,899,151],{"class":73},[48,901,159],{"class":62},[48,903,162],{"class":73},[48,905,906,909,911,914,916,919],{"class":50,"line":66},[48,907,908],{"class":54},"numbers",[48,910,431],{"class":73},[48,912,913],{"class":83},"append",[48,915,74],{"class":73},[48,917,918],{"class":62},"4",[48,920,343],{"class":73},[48,922,923],{"class":50,"line":90},[48,924,94],{"emptyLinePlaceholder":93},[48,926,927,929,931,933],{"class":50,"line":97},[48,928,70],{"class":69},[48,930,74],{"class":73},[48,932,908],{"class":83},[48,934,343],{"class":73},[14,936,346],{},[39,938,940],{"className":41,"code":939,"language":43,"meta":44,"style":44},"[1, 2, 3, 4]\n",[34,941,942],{"__ignoreMap":44},[48,943,944,947,949,951,953,955,957,959,962],{"class":50,"line":51},[48,945,946],{"class":73},"[",[48,948,148],{"class":62},[48,950,151],{"class":73},[48,952,154],{"class":62},[48,954,151],{"class":73},[48,956,159],{"class":62},[48,958,151],{"class":73},[48,960,961],{"class":62}," 4",[48,963,162],{"class":73},[14,965,966],{},"Lists are useful when:",[246,968,969,972],{},[249,970,971],{},"order matters",[249,973,974],{},"you want to add, remove, or change items",[14,976,977,978,431],{},"See ",[450,979,981],{"href":980},"\u002Flearn\u002Fpython-lists-explained-beginner-guide\u002F","Python lists explained for beginners",[462,983,985],{"id":984},"tuple",[34,986,984],{},[14,988,267,989,991],{},[34,990,984],{}," is ordered, but it is not usually changed after creation.",[39,993,995],{"className":41,"code":994,"language":43,"meta":44,"style":44},"point = (10, 20)\nprint(point)\nprint(type(point))\n",[34,996,997,1016,1027],{"__ignoreMap":44},[48,998,999,1002,1004,1007,1009,1011,1014],{"class":50,"line":51},[48,1000,1001],{"class":54},"point ",[48,1003,59],{"class":58},[48,1005,1006],{"class":73}," (",[48,1008,281],{"class":62},[48,1010,151],{"class":73},[48,1012,1013],{"class":62}," 20",[48,1015,343],{"class":73},[48,1017,1018,1020,1022,1025],{"class":50,"line":66},[48,1019,70],{"class":69},[48,1021,74],{"class":73},[48,1023,1024],{"class":83},"point",[48,1026,343],{"class":73},[48,1028,1029,1031,1033,1035,1037,1039],{"class":50,"line":90},[48,1030,70],{"class":69},[48,1032,74],{"class":73},[48,1034,78],{"class":77},[48,1036,74],{"class":73},[48,1038,1024],{"class":83},[48,1040,87],{"class":73},[14,1042,1043],{},"Use tuples when you want a fixed group of values.",[462,1045,1047],{"id":1046},"set",[34,1048,1046],{},[14,1050,267,1051,1053],{},[34,1052,1046],{}," is an unordered collection of unique values.",[39,1055,1057],{"className":41,"code":1056,"language":43,"meta":44,"style":44},"items = {1, 2, 2, 3}\nprint(items)\n",[34,1058,1059,1086],{"__ignoreMap":44},[48,1060,1061,1064,1066,1069,1071,1073,1075,1077,1079,1081,1083],{"class":50,"line":51},[48,1062,1063],{"class":54},"items ",[48,1065,59],{"class":58},[48,1067,1068],{"class":73}," {",[48,1070,148],{"class":62},[48,1072,151],{"class":73},[48,1074,154],{"class":62},[48,1076,151],{"class":73},[48,1078,154],{"class":62},[48,1080,151],{"class":73},[48,1082,159],{"class":62},[48,1084,1085],{"class":73},"}\n",[48,1087,1088,1090,1092,1095],{"class":50,"line":66},[48,1089,70],{"class":69},[48,1091,74],{"class":73},[48,1093,1094],{"class":83},"items",[48,1096,343],{"class":73},[14,1098,1099],{},"Possible output:",[39,1101,1103],{"className":41,"code":1102,"language":43,"meta":44,"style":44},"{1, 2, 3}\n",[34,1104,1105],{"__ignoreMap":44},[48,1106,1107,1110,1112,1114,1116,1118,1120],{"class":50,"line":51},[48,1108,1109],{"class":73},"{",[48,1111,148],{"class":62},[48,1113,151],{"class":73},[48,1115,154],{"class":62},[48,1117,151],{"class":73},[48,1119,159],{"class":62},[48,1121,1085],{"class":73},[14,1123,1124],{},"Sets are useful when duplicates should be removed.",[462,1126,1128],{"id":1127},"dict",[34,1129,1127],{},[14,1131,267,1132,1134,1135,431],{},[34,1133,1127],{}," stores ",[18,1136,1137],{},"key-value pairs",[39,1139,1141],{"className":41,"code":1140,"language":43,"meta":44,"style":44},"student = {\n    \"name\": \"Mia\",\n    \"age\": 14\n}\n\nprint(student[\"name\"])\n",[34,1142,1143,1153,1175,1188,1192,1196],{"__ignoreMap":44},[48,1144,1145,1148,1150],{"class":50,"line":51},[48,1146,1147],{"class":54},"student ",[48,1149,59],{"class":58},[48,1151,1152],{"class":73}," {\n",[48,1154,1155,1158,1160,1162,1165,1167,1170,1172],{"class":50,"line":66},[48,1156,1157],{"class":105},"    \"",[48,1159,712],{"class":109},[48,1161,372],{"class":105},[48,1163,1164],{"class":73},":",[48,1166,106],{"class":105},[48,1168,1169],{"class":109},"Mia",[48,1171,372],{"class":105},[48,1173,1174],{"class":73},",\n",[48,1176,1177,1179,1181,1183,1185],{"class":50,"line":90},[48,1178,1157],{"class":105},[48,1180,527],{"class":109},[48,1182,372],{"class":105},[48,1184,1164],{"class":73},[48,1186,1187],{"class":62}," 14\n",[48,1189,1190],{"class":50,"line":97},[48,1191,1085],{"class":73},[48,1193,1194],{"class":50,"line":116},[48,1195,94],{"emptyLinePlaceholder":93},[48,1197,1198,1200,1202,1205,1207,1209,1211,1213],{"class":50,"line":132},[48,1199,70],{"class":69},[48,1201,74],{"class":73},[48,1203,1204],{"class":83},"student",[48,1206,946],{"class":73},[48,1208,372],{"class":105},[48,1210,712],{"class":109},[48,1212,372],{"class":105},[48,1214,1215],{"class":73},"])\n",[14,1217,346],{},[39,1219,1221],{"className":41,"code":1220,"language":43,"meta":44,"style":44},"Mia\n",[34,1222,1223],{"__ignoreMap":44},[48,1224,1225],{"class":50,"line":51},[48,1226,1220],{"class":54},[14,1228,1229,1230,431],{},"Dictionaries are useful when you want to look up values by a name or key. See ",[450,1231,1233],{"href":1232},"\u002Flearn\u002Fpython-dictionaries-explained\u002F","Python dictionaries explained",[26,1235,1237],{"id":1236},"how-to-check-a-values-type","How to check a value's type",[14,1239,32,1240,1243],{},[34,1241,1242],{},"type(value)"," to inspect a value.",[39,1245,1247],{"className":41,"code":1246,"language":43,"meta":44,"style":44},"print(type(10))\nprint(type(3.14))\nprint(type(\"hello\"))\nprint(type([1, 2, 3]))\n",[34,1248,1249,1263,1277,1295],{"__ignoreMap":44},[48,1250,1251,1253,1255,1257,1259,1261],{"class":50,"line":51},[48,1252,70],{"class":69},[48,1254,74],{"class":73},[48,1256,78],{"class":77},[48,1258,74],{"class":73},[48,1260,281],{"class":62},[48,1262,87],{"class":73},[48,1264,1265,1267,1269,1271,1273,1275],{"class":50,"line":66},[48,1266,70],{"class":69},[48,1268,74],{"class":73},[48,1270,78],{"class":77},[48,1272,74],{"class":73},[48,1274,563],{"class":62},[48,1276,87],{"class":73},[48,1278,1279,1281,1283,1285,1287,1289,1291,1293],{"class":50,"line":90},[48,1280,70],{"class":69},[48,1282,74],{"class":73},[48,1284,78],{"class":77},[48,1286,74],{"class":73},[48,1288,372],{"class":105},[48,1290,110],{"class":109},[48,1292,372],{"class":105},[48,1294,87],{"class":73},[48,1296,1297,1299,1301,1303,1306,1308,1310,1312,1314,1316],{"class":50,"line":97},[48,1298,70],{"class":69},[48,1300,74],{"class":73},[48,1302,78],{"class":77},[48,1304,1305],{"class":73},"([",[48,1307,148],{"class":62},[48,1309,151],{"class":73},[48,1311,154],{"class":62},[48,1313,151],{"class":73},[48,1315,159],{"class":62},[48,1317,1318],{"class":73},"]))\n",[14,1320,1321],{},"This is especially useful when:",[246,1323,1324,1327,1330],{},[249,1325,1326],{},"input data is unclear",[249,1328,1329],{},"you are reading data from a file",[249,1331,1332],{},"an error suggests the wrong type is being used",[14,1334,1335,1336,1339],{},"You can also use ",[34,1337,1338],{},"isinstance()"," when you want to check whether a value is a specific type:",[39,1341,1343],{"className":41,"code":1342,"language":43,"meta":44,"style":44},"value = \"hello\"\n\nprint(isinstance(value, str))\nprint(isinstance(value, int))\n",[34,1344,1345,1357,1361,1381],{"__ignoreMap":44},[48,1346,1347,1349,1351,1353,1355],{"class":50,"line":51},[48,1348,742],{"class":54},[48,1350,59],{"class":58},[48,1352,106],{"class":105},[48,1354,110],{"class":109},[48,1356,113],{"class":105},[48,1358,1359],{"class":50,"line":66},[48,1360,94],{"emptyLinePlaceholder":93},[48,1362,1363,1365,1367,1370,1372,1374,1376,1379],{"class":50,"line":90},[48,1364,70],{"class":69},[48,1366,74],{"class":73},[48,1368,1369],{"class":69},"isinstance",[48,1371,74],{"class":73},[48,1373,764],{"class":83},[48,1375,151],{"class":73},[48,1377,1378],{"class":77}," str",[48,1380,87],{"class":73},[48,1382,1383,1385,1387,1389,1391,1393,1395,1398],{"class":50,"line":97},[48,1384,70],{"class":69},[48,1386,74],{"class":73},[48,1388,1369],{"class":69},[48,1390,74],{"class":73},[48,1392,764],{"class":83},[48,1394,151],{"class":73},[48,1396,1397],{"class":77}," int",[48,1399,87],{"class":73},[14,1401,346],{},[39,1403,1405],{"className":41,"code":1404,"language":43,"meta":44,"style":44},"True\nFalse\n",[34,1406,1407,1412],{"__ignoreMap":44},[48,1408,1409],{"class":50,"line":51},[48,1410,1411],{"class":813},"True\n",[48,1413,1414],{"class":50,"line":66},[48,1415,1416],{"class":813},"False\n",[14,1418,857,1419,431],{},[450,1420,1422],{"href":1421},"\u002Freference\u002Fpython-type-function-explained\u002F","Python type() function explained",[26,1424,1426],{"id":1425},"choosing-the-right-type","Choosing the right type",[14,1428,1429],{},"Use these simple rules as a starting point:",[246,1431,1432,1437,1442,1447,1452,1457],{},[249,1433,32,1434,1436],{},[34,1435,201],{}," for counting and whole-number values",[249,1438,32,1439,1441],{},[34,1440,547],{}," for decimal values",[249,1443,32,1444,1446],{},[34,1445,218],{}," for names, messages, and text input",[249,1448,32,1449,1451],{},[34,1450,233],{}," for ordered groups you need to change",[249,1453,32,1454,1456],{},[34,1455,1127],{}," when values should be looked up by key",[249,1458,32,1459,1461],{},[34,1460,1046],{}," when you want unique values only",[14,1463,474],{},[39,1465,1467],{"className":41,"code":1466,"language":43,"meta":44,"style":44},"count = 5                  # int\nprice = 8.99               # float\nusername = \"sam\"           # str\nscores = [80, 90, 75]      # list\nuser = {\"name\": \"Sam\"}     # dict\ntags = {\"python\", \"code\"}  # set\n",[34,1468,1469,1482,1494,1511,1539,1569],{"__ignoreMap":44},[48,1470,1471,1473,1475,1478],{"class":50,"line":51},[48,1472,510],{"class":54},[48,1474,59],{"class":58},[48,1476,1477],{"class":62}," 5",[48,1479,1481],{"class":1480},"sutJx","                  # int\n",[48,1483,1484,1486,1488,1491],{"class":50,"line":66},[48,1485,583],{"class":54},[48,1487,59],{"class":58},[48,1489,1490],{"class":62}," 8.99",[48,1492,1493],{"class":1480},"               # float\n",[48,1495,1496,1499,1501,1503,1506,1508],{"class":50,"line":90},[48,1497,1498],{"class":54},"username ",[48,1500,59],{"class":58},[48,1502,106],{"class":105},[48,1504,1505],{"class":109},"sam",[48,1507,372],{"class":105},[48,1509,1510],{"class":1480},"           # str\n",[48,1512,1513,1516,1518,1520,1523,1525,1528,1530,1533,1536],{"class":50,"line":97},[48,1514,1515],{"class":54},"scores ",[48,1517,59],{"class":58},[48,1519,145],{"class":73},[48,1521,1522],{"class":62},"80",[48,1524,151],{"class":73},[48,1526,1527],{"class":62}," 90",[48,1529,151],{"class":73},[48,1531,1532],{"class":62}," 75",[48,1534,1535],{"class":73},"]",[48,1537,1538],{"class":1480},"      # list\n",[48,1540,1541,1544,1546,1548,1550,1552,1554,1556,1558,1561,1563,1566],{"class":50,"line":116},[48,1542,1543],{"class":54},"user ",[48,1545,59],{"class":58},[48,1547,1068],{"class":73},[48,1549,372],{"class":105},[48,1551,712],{"class":109},[48,1553,372],{"class":105},[48,1555,1164],{"class":73},[48,1557,106],{"class":105},[48,1559,1560],{"class":109},"Sam",[48,1562,372],{"class":105},[48,1564,1565],{"class":73},"}",[48,1567,1568],{"class":1480},"     # dict\n",[48,1570,1571,1574,1576,1578,1580,1582,1584,1586,1588,1590,1592,1594],{"class":50,"line":132},[48,1572,1573],{"class":54},"tags ",[48,1575,59],{"class":58},[48,1577,1068],{"class":73},[48,1579,372],{"class":105},[48,1581,43],{"class":109},[48,1583,372],{"class":105},[48,1585,151],{"class":73},[48,1587,106],{"class":105},[48,1589,34],{"class":109},[48,1591,372],{"class":105},[48,1593,1565],{"class":73},[48,1595,1596],{"class":1480},"  # set\n",[14,1598,1599],{},"If you are unsure, ask:",[246,1601,1602,1605,1608,1611,1614],{},[249,1603,1604],{},"Is this a number or text?",[249,1606,1607],{},"Do I need one value or many values?",[249,1609,1610],{},"Does order matter?",[249,1612,1613],{},"Do I need to change it later?",[249,1615,1616],{},"Do I need names for each value?",[26,1618,1620],{"id":1619},"type-conversion-basics","Type conversion basics",[14,1622,1623],{},"Python can convert values from one type to another with functions such as:",[246,1625,1626,1631,1636],{},[249,1627,1628],{},[34,1629,1630],{},"int()",[249,1632,1633],{},[34,1634,1635],{},"float()",[249,1637,1638],{},[34,1639,1640],{},"str()",[14,1642,1643],{},"Example:",[39,1645,1647],{"className":41,"code":1646,"language":43,"meta":44,"style":44},"text_number = \"42\"\n\nnumber = int(text_number)\n\nprint(number)\nprint(type(number))\n",[34,1648,1649,1663,1667,1683,1687,1698],{"__ignoreMap":44},[48,1650,1651,1654,1656,1658,1661],{"class":50,"line":51},[48,1652,1653],{"class":54},"text_number ",[48,1655,59],{"class":58},[48,1657,106],{"class":105},[48,1659,1660],{"class":109},"42",[48,1662,113],{"class":105},[48,1664,1665],{"class":50,"line":66},[48,1666,94],{"emptyLinePlaceholder":93},[48,1668,1669,1672,1674,1676,1678,1681],{"class":50,"line":90},[48,1670,1671],{"class":54},"number ",[48,1673,59],{"class":58},[48,1675,1397],{"class":77},[48,1677,74],{"class":73},[48,1679,1680],{"class":83},"text_number",[48,1682,343],{"class":73},[48,1684,1685],{"class":50,"line":97},[48,1686,94],{"emptyLinePlaceholder":93},[48,1688,1689,1691,1693,1696],{"class":50,"line":116},[48,1690,70],{"class":69},[48,1692,74],{"class":73},[48,1694,1695],{"class":83},"number",[48,1697,343],{"class":73},[48,1699,1700,1702,1704,1706,1708,1710],{"class":50,"line":132},[48,1701,70],{"class":69},[48,1703,74],{"class":73},[48,1705,78],{"class":77},[48,1707,74],{"class":73},[48,1709,1695],{"class":83},[48,1711,87],{"class":73},[14,1713,346],{},[39,1715,1717],{"className":41,"code":1716,"language":43,"meta":44,"style":44},"42\n\u003Cclass 'int'>\n",[34,1718,1719,1724],{"__ignoreMap":44},[48,1720,1721],{"class":50,"line":51},[48,1722,1723],{"class":62},"42\n",[48,1725,1726,1728,1730,1732,1734,1736],{"class":50,"line":66},[48,1727,191],{"class":58},[48,1729,195],{"class":194},[48,1731,198],{"class":105},[48,1733,201],{"class":109},[48,1735,204],{"class":105},[48,1737,207],{"class":58},[14,1739,1740,1741,1744],{},"This is very common when working with user input, because ",[34,1742,1743],{},"input()"," returns a string by default.",[39,1746,1748],{"className":41,"code":1747,"language":43,"meta":44,"style":44},"age_text = input(\"Enter your age: \")\nage = int(age_text)\n\nprint(age + 1)\n",[34,1749,1750,1771,1786,1790],{"__ignoreMap":44},[48,1751,1752,1755,1757,1760,1762,1764,1767,1769],{"class":50,"line":51},[48,1753,1754],{"class":54},"age_text ",[48,1756,59],{"class":58},[48,1758,1759],{"class":69}," input",[48,1761,74],{"class":73},[48,1763,372],{"class":105},[48,1765,1766],{"class":109},"Enter your age: ",[48,1768,372],{"class":105},[48,1770,343],{"class":73},[48,1772,1773,1775,1777,1779,1781,1784],{"class":50,"line":66},[48,1774,500],{"class":54},[48,1776,59],{"class":58},[48,1778,1397],{"class":77},[48,1780,74],{"class":73},[48,1782,1783],{"class":83},"age_text",[48,1785,343],{"class":73},[48,1787,1788],{"class":50,"line":90},[48,1789,94],{"emptyLinePlaceholder":93},[48,1791,1792,1794,1796,1798,1801,1804],{"class":50,"line":97},[48,1793,70],{"class":69},[48,1795,74],{"class":73},[48,1797,500],{"class":83},[48,1799,1800],{"class":58},"+",[48,1802,1803],{"class":62}," 1",[48,1805,343],{"class":73},[14,1807,1808],{},"Be careful: not every string can be converted to a number.",[39,1810,1812],{"className":41,"code":1811,"language":43,"meta":44,"style":44},"value = \"hello\"\nnumber = int(value)\n",[34,1813,1814,1826],{"__ignoreMap":44},[48,1815,1816,1818,1820,1822,1824],{"class":50,"line":51},[48,1817,742],{"class":54},[48,1819,59],{"class":58},[48,1821,106],{"class":105},[48,1823,110],{"class":109},[48,1825,113],{"class":105},[48,1827,1828,1830,1832,1834,1836,1838],{"class":50,"line":66},[48,1829,1671],{"class":54},[48,1831,59],{"class":58},[48,1833,1397],{"class":77},[48,1835,74],{"class":73},[48,1837,764],{"class":83},[48,1839,343],{"class":73},[14,1841,427,1842,431],{},[34,1843,1844],{},"ValueError",[14,1846,1847,1848,1852,1853,431],{},"If you want to practice this next, read ",[450,1849,1851],{"href":1850},"\u002Flearn\u002Ftype-conversion-in-python-casting-between-types\u002F","type conversion in Python"," or ",[450,1854,1856],{"href":1855},"\u002Fhow-to\u002Fhow-to-convert-string-to-int-in-python\u002F","how to convert string to int in Python",[26,1858,1860],{"id":1859},"common-beginner-confusion","Common beginner confusion",[14,1862,1863],{},"Here are some common things that confuse new Python learners.",[246,1865,1866,1873,1878,1886],{},[249,1867,1868,1869,1852,1871],{},"Numbers in quotes are strings, not ",[34,1870,201],{},[34,1872,547],{},[249,1874,1875,1877],{},[34,1876,1743],{}," returns a string by default",[249,1879,1880,1882,1883,1885],{},[34,1881,790],{}," and ",[34,1884,795],{}," are booleans, not strings",[249,1887,1888],{},"Lists, tuples, sets, and dictionaries all store groups of values, but they behave differently",[14,1890,1643],{},[39,1892,1894],{"className":41,"code":1893,"language":43,"meta":44,"style":44},"a = \"5\"\nb = 5\n\nprint(type(a))\nprint(type(b))\n",[34,1895,1896,1910,1920,1924,1938],{"__ignoreMap":44},[48,1897,1898,1901,1903,1905,1908],{"class":50,"line":51},[48,1899,1900],{"class":54},"a ",[48,1902,59],{"class":58},[48,1904,106],{"class":105},[48,1906,1907],{"class":109},"5",[48,1909,113],{"class":105},[48,1911,1912,1915,1917],{"class":50,"line":66},[48,1913,1914],{"class":54},"b ",[48,1916,59],{"class":58},[48,1918,1919],{"class":62}," 5\n",[48,1921,1922],{"class":50,"line":90},[48,1923,94],{"emptyLinePlaceholder":93},[48,1925,1926,1928,1930,1932,1934,1936],{"class":50,"line":97},[48,1927,70],{"class":69},[48,1929,74],{"class":73},[48,1931,78],{"class":77},[48,1933,74],{"class":73},[48,1935,450],{"class":83},[48,1937,87],{"class":73},[48,1939,1940,1942,1944,1946,1948,1951],{"class":50,"line":116},[48,1941,70],{"class":69},[48,1943,74],{"class":73},[48,1945,78],{"class":77},[48,1947,74],{"class":73},[48,1949,1950],{"class":83},"b",[48,1952,87],{"class":73},[14,1954,346],{},[39,1956,1958],{"className":41,"code":1957,"language":43,"meta":44,"style":44},"\u003Cclass 'str'>\n\u003Cclass 'int'>\n",[34,1959,1960,1974],{"__ignoreMap":44},[48,1961,1962,1964,1966,1968,1970,1972],{"class":50,"line":51},[48,1963,191],{"class":58},[48,1965,195],{"class":194},[48,1967,198],{"class":105},[48,1969,218],{"class":109},[48,1971,204],{"class":105},[48,1973,207],{"class":58},[48,1975,1976,1978,1980,1982,1984,1986],{"class":50,"line":66},[48,1977,191],{"class":58},[48,1979,195],{"class":194},[48,1981,198],{"class":105},[48,1983,201],{"class":109},[48,1985,204],{"class":105},[48,1987,207],{"class":58},[26,1989,1991],{"id":1990},"common-mistakes","Common mistakes",[14,1993,1994],{},"These problems often happen when learning data types:",[246,1996,1997,2000,2003,2006,2009],{},[249,1998,1999],{},"Treating user input as a number without converting it",[249,2001,2002],{},"Putting numbers in quotes and expecting math to work",[249,2004,2005],{},"Using the wrong collection type for the task",[249,2007,2008],{},"Confusing list, tuple, set, and dictionary behavior",[249,2010,2011],{},"Trying to combine values of different types directly",[14,2013,2014],{},"Helpful debugging steps:",[39,2016,2018],{"className":41,"code":2017,"language":43,"meta":44,"style":44},"print(type(value))\nprint(value)\nprint(repr(value))\nprint(isinstance(value, int))\nprint(isinstance(value, str))\n",[34,2019,2020,2034,2044,2059,2077],{"__ignoreMap":44},[48,2021,2022,2024,2026,2028,2030,2032],{"class":50,"line":51},[48,2023,70],{"class":69},[48,2025,74],{"class":73},[48,2027,78],{"class":77},[48,2029,74],{"class":73},[48,2031,764],{"class":83},[48,2033,87],{"class":73},[48,2035,2036,2038,2040,2042],{"class":50,"line":66},[48,2037,70],{"class":69},[48,2039,74],{"class":73},[48,2041,764],{"class":83},[48,2043,343],{"class":73},[48,2045,2046,2048,2050,2053,2055,2057],{"class":50,"line":90},[48,2047,70],{"class":69},[48,2049,74],{"class":73},[48,2051,2052],{"class":69},"repr",[48,2054,74],{"class":73},[48,2056,764],{"class":83},[48,2058,87],{"class":73},[48,2060,2061,2063,2065,2067,2069,2071,2073,2075],{"class":50,"line":97},[48,2062,70],{"class":69},[48,2064,74],{"class":73},[48,2066,1369],{"class":69},[48,2068,74],{"class":73},[48,2070,764],{"class":83},[48,2072,151],{"class":73},[48,2074,1397],{"class":77},[48,2076,87],{"class":73},[48,2078,2079,2081,2083,2085,2087,2089,2091,2093],{"class":50,"line":116},[48,2080,70],{"class":69},[48,2082,74],{"class":73},[48,2084,1369],{"class":69},[48,2086,74],{"class":73},[48,2088,764],{"class":83},[48,2090,151],{"class":73},[48,2092,1378],{"class":77},[48,2094,87],{"class":73},[14,2096,2097],{},"What these do:",[246,2099,2100,2106,2112,2118,2124],{},[249,2101,2102,2105],{},[34,2103,2104],{},"print(type(value))"," shows the type",[249,2107,2108,2111],{},[34,2109,2110],{},"print(value)"," shows the normal output",[249,2113,2114,2117],{},[34,2115,2116],{},"print(repr(value))"," shows a more exact representation, which is useful for spotting quotes and special characters",[249,2119,2120,2123],{},[34,2121,2122],{},"isinstance(value, int)"," checks whether the value is an integer",[249,2125,2126,2129],{},[34,2127,2128],{},"isinstance(value, str)"," checks whether the value is a string",[14,2131,2132],{},"If you run into conversion problems, these pages may help:",[246,2134,2135,2141],{},[249,2136,2137],{},[450,2138,2140],{"href":2139},"\u002Ferrors\u002Ftypeerror-can-only-concatenate-str-not-int-to-str-fix\u002F","TypeError: can only concatenate str not int to str",[249,2142,2143],{},[450,2144,2146],{"href":2145},"\u002Ferrors\u002Fvalueerror-invalid-literal-for-int-with-base-10-fix\u002F","ValueError: invalid literal for int() with base 10",[26,2148,2150],{"id":2149},"good-next-steps","Good next steps",[14,2152,2153],{},"After this overview, the best next step is to learn one type at a time.",[14,2155,2156],{},"A good order is:",[2158,2159,2160,2163,2166,2169],"ol",{},[249,2161,2162],{},"Strings",[249,2164,2165],{},"Numbers",[249,2167,2168],{},"Lists",[249,2170,2171],{},"Type conversion",[14,2173,2174],{},"That gives you the basics needed for most beginner Python programs.",[26,2176,2178],{"id":2177},"faq","FAQ",[462,2180,2182],{"id":2181},"what-is-a-data-type-in-python","What is a data type in Python?",[14,2184,2185],{},"A data type is the kind of value a variable holds, such as a number, string, list, or dictionary.",[462,2187,2189],{"id":2188},"how-do-i-check-a-data-type-in-python","How do I check a data type in Python?",[14,2191,2192,2193,2195,2196,1852,2199,431],{},"Use the ",[34,2194,36],{}," function, such as ",[34,2197,2198],{},"type(10)",[34,2200,2201],{},"type(\"hello\")",[462,2203,2205],{"id":2204},"what-are-the-main-python-data-types-for-beginners","What are the main Python data types for beginners?",[14,2207,2208,2209,2211,2212,2211,2214,2211,2216,2211,2218,2211,2220,2211,2222,2224,2225,431],{},"The most important ones are ",[34,2210,201],{},", ",[34,2213,547],{},[34,2215,218],{},[34,2217,776],{},[34,2219,233],{},[34,2221,984],{},[34,2223,1046],{},", and ",[34,2226,1127],{},[462,2228,2230,2231,2233],{"id":2229},"is-input-a-number-in-python","Is ",[34,2232,1743],{}," a number in Python?",[14,2235,2236,2237,2239,2240,1852,2242,431],{},"No. ",[34,2238,1743],{}," returns a string unless you convert it with ",[34,2241,1630],{},[34,2243,1635],{},[462,2245,2247],{"id":2246},"what-is-the-difference-between-list-and-tuple","What is the difference between list and tuple?",[14,2249,2250],{},"A list can be changed after creation. A tuple cannot be changed in the usual way.",[26,2252,2254],{"id":2253},"see-also","See also",[246,2256,2257,2261,2265,2269,2274],{},[249,2258,2259],{},[450,2260,453],{"href":452},[249,2262,2263],{},[450,2264,773],{"href":772},[249,2266,2267],{},[450,2268,981],{"href":980},[249,2270,2271],{},[450,2272,2273],{"href":1850},"Type conversion in Python",[249,2275,2276],{},[450,2277,1422],{"href":1421},[2279,2280,2281],"style",{},"html pre.shiki code .su5hD, html code.shiki .su5hD{--shiki-light:#90A4AE;--shiki-default:#24292E;--shiki-dark:#E1E4E8}html pre.shiki code .smGrS, html code.shiki .smGrS{--shiki-light:#39ADB5;--shiki-default:#D73A49;--shiki-dark:#F97583}html pre.shiki code .srdBf, html code.shiki .srdBf{--shiki-light:#F76D47;--shiki-default:#005CC5;--shiki-dark:#79B8FF}html pre.shiki code .sptTA, html code.shiki .sptTA{--shiki-light:#6182B8;--shiki-default:#005CC5;--shiki-dark:#79B8FF}html pre.shiki code .sP7_E, html code.shiki .sP7_E{--shiki-light:#39ADB5;--shiki-default:#24292E;--shiki-dark:#E1E4E8}html pre.shiki code .sZMiF, html code.shiki .sZMiF{--shiki-light:#E2931D;--shiki-default:#005CC5;--shiki-dark:#79B8FF}html pre.shiki code .slqww, html code.shiki .slqww{--shiki-light:#6182B8;--shiki-default:#24292E;--shiki-dark:#E1E4E8}html pre.shiki code .sjJ54, html code.shiki .sjJ54{--shiki-light:#39ADB5;--shiki-default:#032F62;--shiki-dark:#9ECBFF}html pre.shiki code .s_sjI, html code.shiki .s_sjI{--shiki-light:#91B859;--shiki-default:#032F62;--shiki-dark:#9ECBFF}html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html pre.shiki code .sbsja, html code.shiki .sbsja{--shiki-light:#9C3EDA;--shiki-default:#D73A49;--shiki-dark:#F97583}html pre.shiki code .s39Yj, html code.shiki .s39Yj{--shiki-light:#39ADB5;--shiki-default:#005CC5;--shiki-dark:#79B8FF}html pre.shiki code .sutJx, html code.shiki .sutJx{--shiki-light:#90A4AE;--shiki-light-font-style:italic;--shiki-default:#6A737D;--shiki-default-font-style:inherit;--shiki-dark:#6A737D;--shiki-dark-font-style:inherit}",{"title":44,"searchDepth":66,"depth":66,"links":2283},[2284,2285,2286,2287,2288,2294,2300,2301,2302,2303,2304,2305,2306,2314],{"id":28,"depth":66,"text":29},{"id":243,"depth":66,"text":244},{"id":263,"depth":66,"text":264},{"id":314,"depth":66,"text":315},{"id":456,"depth":66,"text":457,"children":2289},[2290,2291,2292,2293],{"id":201,"depth":90,"text":201},{"id":547,"depth":90,"text":547},{"id":218,"depth":90,"text":218},{"id":776,"depth":90,"text":776},{"id":864,"depth":66,"text":865,"children":2295},[2296,2297,2298,2299],{"id":233,"depth":90,"text":233},{"id":984,"depth":90,"text":984},{"id":1046,"depth":90,"text":1046},{"id":1127,"depth":90,"text":1127},{"id":1236,"depth":66,"text":1237},{"id":1425,"depth":66,"text":1426},{"id":1619,"depth":66,"text":1620},{"id":1859,"depth":66,"text":1860},{"id":1990,"depth":66,"text":1991},{"id":2149,"depth":66,"text":2150},{"id":2177,"depth":66,"text":2178,"children":2307},[2308,2309,2310,2311,2313],{"id":2181,"depth":90,"text":2182},{"id":2188,"depth":90,"text":2189},{"id":2204,"depth":90,"text":2205},{"id":2229,"depth":90,"text":2312},"Is input() a number in Python?",{"id":2246,"depth":90,"text":2247},{"id":2253,"depth":66,"text":2254},"Master python data types overview in our comprehensive Python beginner guide.","md",{},"\u002Flearn\u002Fpython-data-types-overview",{"title":5,"description":2315},"learn\u002Fpython-data-types-overview","KbkurlyY48Ep9-o6F9QXdQPwFlygCOmREpPbTT9tSFY",1777585494078]