CINXE.COM

Highest scored 'python' questions - Stack Overflow

<!DOCTYPE html> <html class="html__responsive " lang="en"> <head><script type="text/javascript" src="/_static/js/bundle-playback.js?v=HxkREWBo" charset="utf-8"></script> <script type="text/javascript" src="/_static/js/wombat.js?v=txqj7nKC" charset="utf-8"></script> <script>window.RufflePlayer=window.RufflePlayer||{};window.RufflePlayer.config={"autoplay":"on","unmuteOverlay":"hidden"};</script> <script type="text/javascript" src="/_static/js/ruffle/ruffle.js"></script> <script type="text/javascript"> __wm.init("https://web.archive.org/web"); __wm.wombat("https://stackoverflow.com/questions/tagged/python","20230306154331","https://web.archive.org/","web","/_static/", "1678117411"); </script> <link rel="stylesheet" type="text/css" href="/_static/css/banner-styles.css?v=S1zqJCYt" /> <link rel="stylesheet" type="text/css" href="/_static/css/iconochive.css?v=3PDvdIFv" /> <!-- End Wayback Rewrite JS Include --> <title>Highest scored &#39;python&#39; questions - Stack Overflow</title> <link rel="shortcut icon" href="https://web.archive.org/web/20230306154331im_/https://cdn.sstatic.net/Sites/stackoverflow/Img/favicon.ico?v=ec617d715196"> <link rel="apple-touch-icon" href="https://web.archive.org/web/20230306154331im_/https://cdn.sstatic.net/Sites/stackoverflow/Img/apple-touch-icon.png?v=c78bd457575a"> <link rel="image_src" href="https://web.archive.org/web/20230306154331im_/https://cdn.sstatic.net/Sites/stackoverflow/Img/apple-touch-icon.png?v=c78bd457575a"> <link rel="search" type="application/opensearchdescription+xml" title="Stack Overflow" href="/web/20230306154331/https://stackoverflow.com/opensearch.xml"> <meta name="viewport" content="width=device-width, height=device-height, initial-scale=1.0, minimum-scale=1.0"> <meta property="og:type" content="website"/> <meta property="og:url" content="https://web.archive.org/web/20230306154331/https://stackoverflow.com/questions/tagged/python"/> <meta property="og:site_name" content="Stack Overflow"/> <meta property="og:image" itemprop="image primaryImageOfPage" content="https://web.archive.org/web/20230306154331im_/https://cdn.sstatic.net/Sites/stackoverflow/Img/apple-touch-icon@2.png?v=73d79a89bded"/> <meta name="twitter:card" content="summary"/> <meta name="twitter:domain" content="stackoverflow.com"/> <meta name="twitter:title" property="og:title" itemprop="name" content="Highest scored 'python' questions"/> <meta name="twitter:description" property="og:description" itemprop="description" content="Stack Overflow | The World’s Largest Online Community for Developers"/> <script id="webpack-public-path" type="text/uri-list">https://cdn.sstatic.net/</script> <script src="/web/20230306154331js_/https://stackoverflow.com/Content/Js/third-party/jquery-1.12.4.min.js"></script> <script defer src="https://web.archive.org/web/20230306154331js_/https://cdn.sstatic.net/Js/third-party/npm/@stackoverflow/stacks/dist/js/stacks.min.js?v=1d4d417772d8"></script> <script src="https://web.archive.org/web/20230306154331js_/https://cdn.sstatic.net/Js/stub.en.js?v=e56950123f65"></script> <link rel="stylesheet" type="text/css" href="https://web.archive.org/web/20230306154331cs_/https://cdn.sstatic.net/Shared/stacks.css?v=56e23d88c162"> <link rel="stylesheet" type="text/css" href="https://web.archive.org/web/20230306154331cs_/https://cdn.sstatic.net/Sites/stackoverflow/primary.css?v=453a5648c50d"> <link rel="stylesheet" type="text/css" href="https://web.archive.org/web/20230306154331cs_/https://cdn.sstatic.net/Sites/stackoverflow/secondary.css?v=6793be5668e3"> <link rel="alternate" type="application/atom+xml" title="Highest scored python questions feed" href="/web/20230306154331/https://stackoverflow.com/feeds/tag?tagnames=python&amp;sort=votes"/> <link rel="stylesheet" type="text/css" href="https://web.archive.org/web/20230306154331cs_/https://cdn.sstatic.net/Shared/Channels/channels.css?v=a5fae8812988"> <script type="application/json" data-role="module-args" data-module-name="Shared/options.mod">{"options":{"locale":"en","serverTime":1678117411,"routeName":"Questions/ListByTag","stackAuthUrl":"https://web.archive.org/web/20230306154331/https://stackauth.com","networkMetaHostname":"meta.stackexchange.com","site":{"name":"Stack Overflow","description":"Q\u0026A for professional and enthusiast programmers","isNoticesTabEnabled":true,"enableNewTagCreationWarning":true,"insertSpaceAfterNameTabCompletion":false,"id":1,"cookieDomain":".stackoverflow.com","childUrl":"https://web.archive.org/web/20230306154331/https://meta.stackoverflow.com","negativeVoteScoreFloor":null,"enableSocialMediaInSharePopup":true,"protocol":"https"},"user":{"fkey":"046c469d7424fabfb43b3cea8db600e74ca8f04ba4d38397f5b408c6dfc52f29","tid":"3a7b3d86-7982-8e0e-f566-6d472a249038","rep":0,"isAnonymous":true,"isAnonymousNetworkWide":true},"events":{"postType":{"question":1},"postEditionSection":{"title":1,"body":2,"tags":3}}}}</script> <script type="application/json" data-role="module-args" data-module-name="Shared/settings.mod">{"settings":{"userMessaging":{"showNewFeatureNotice":true},"tags":{},"subscriptions":{"defaultBasicMaxTrueUpSeats":250,"defaultFreemiumMaxTrueUpSeats":50,"defaultMaxTrueUpSeats":1000},"snippets":{"renderDomain":"stacksnippets.net","snippetsEnabled":true},"site":{"allowImageUploads":true,"enableImgurHttps":true,"enableUserHovercards":true,"forceHttpsImages":true,"stacksEditorPreviewEnabled":true,"styleCode":true},"questions":{"enableQuestionTitleLengthLiveWarning":true,"enableSavesFeature":true,"maxTitleSize":150,"questionTitleLengthStartLiveWarningChars":50},"intercom":{"appId":"inf0secd","hostBaseUrl":"https://web.archive.org/web/20230306154331/https://stacksnippets.net"},"paths":{"jQueryUICSSPath":"https://web.archive.org/web/20230306154331/https://ajax.googleapis.com/ajax/libs/jqueryui/1.12.0/themes/smoothness/jquery-ui.css","jQueryUIJSPath":"https://web.archive.org/web/20230306154331/https://ajax.googleapis.com/ajax/libs/jqueryui/1.12.0/jquery-ui.min.js"},"monitoring":{"clientTimingsAbsoluteTimeout":30000,"clientTimingsDebounceTimeout":1000},"mentions":{"maxNumUsersInDropdown":50},"markdown":{"enableTables":true},"legal":{"oneTrustConfigId":"c3d9f1e3-55f3-4eba-b268-46cee4c6789c"},"flags":{"allowRetractingCommentFlags":true,"allowRetractingFlags":true},"elections":{"opaVoteResultsBaseUrl":"https://web.archive.org/web/20230306154331/https://www.opavote.com/results/"},"comments":{},"accounts":{"currentPasswordRequiredForChangingStackIdPassword":true}}}</script> <script>StackExchange.init();</script> <script> StackExchange.using.setCacheBreakers({"Js/adops.en.js":"6da43f5e0a84","Js/ask.en.js":"","Js/begin-edit-event.en.js":"20edbaccceae","Js/copy-transpiled.en.js":"e7855bee94f2","Js/events.en.js":"","Js/explore-qlist.en.js":"2b1f34938b8b","Js/full-anon.en.js":"6a00afec4f5e","Js/full.en.js":"c8909108cd52","Js/highlightjs-loader.en.js":"a284064706b3","Js/inline-tag-editing.en.js":"629d801833ec","Js/keyboard-shortcuts.en.js":"4cb9eae35625","Js/markdown-it-loader.en.js":"5818ef89ff9d","Js/mentions-transpiled.en.js":"78637d7eac99","Js/moderator.en.js":"d88c424a0972","Js/postCollections-transpiled.en.js":"fac92aa0ceeb","Js/post-validation.en.js":"6da722d510e3","Js/question-editor.en.js":"","Js/review-v2-transpiled.en.js":"ae1e01b7e8cb","Js/revisions.en.js":"a86490719687","Js/stacks-editor.en.js":"4eaa25f823da","Js/tageditor.en.js":"e5db6df2411b","Js/tageditornew.en.js":"c4fc98223de1","Js/tagsuggestions.en.js":"0d912930b14c","Js/unlimited-transpiled.en.js":"7ed67670b600","Js/wmd.en.js":"67025ccb344d","Js/snippet-javascript-codemirror.en.js":"73fce5cc7219"}); StackExchange.using("gps", function() { StackExchange.gps.init(false); }); </script> <noscript id="noscript-css"><style>body,.s-topbar{margin-top:1.9em}</style></noscript> </head> <body class="tagged-questions-page unified-theme"> <div id="notify-container"></div> <div id="custom-header"></div> <header class="s-topbar ps-fixed t0 l0 js-top-bar"> <div class="s-topbar--container"> <a href="#" class="s-topbar--menu-btn js-left-sidebar-toggle" role="menuitem" aria-haspopup="true" aria-controls="left-sidebar" aria-expanded="false"><span></span></a> <div class="topbar-dialog leftnav-dialog js-leftnav-dialog dno"> <div class="left-sidebar js-unpinned-left-sidebar" data-can-be="left-sidebar" data-is-here-when="sm"></div> </div> <a href="https://web.archive.org/web/20230306154331/https://stackoverflow.com/" class="s-topbar--logo js-gps-track" data-gps-track="top_nav.click({is_current:false, location:5, destination:8})"> <span class="-img _glyph">Stack Overflow</span> </a> <ol class="s-navigation" role="presentation"> <li class="md:d-none"> <a href="https://web.archive.org/web/20230306154331/https://stackoverflow.co/" class="s-navigation--item js-gps-track" data-gps-track="top_nav.products.click({location:5, destination:7})" data-ga="[&quot;top navigation&quot;,&quot;about menu click&quot;,null,null,null]">About</a> </li> <li> <a href="#" class="s-navigation--item js-gps-track js-products-menu" aria-controls="products-popover" data-controller="s-popover" data-action="s-popover#toggle" data-s-popover-placement="bottom" data-s-popover-toggle-class="is-selected" data-gps-track="top_nav.products.click({location:5, destination:1})" data-ga="[&quot;top navigation&quot;,&quot;products menu click&quot;,null,null,null]"> Products </a> </li> <li class="md:d-none"> <a href="/web/20230306154331/https://stackoverflow.com/teams" class="s-navigation--item js-gps-track" data-gps-track="top_nav.products.click({location:5, destination:7})" data-ga="[&quot;top navigation&quot;,&quot;learn more - teams&quot;,null,null,null]">For Teams</a> </li> </ol> <div class="s-popover ws2 mtn2 p0" id="products-popover" role="menu" aria-hidden="true"> <div class="s-popover--arrow"></div> <ol class="list-reset s-anchors s-anchors__inherit"> <li class="m6"> <a href="/web/20230306154331/https://stackoverflow.com/questions" class="bar-sm p6 d-block h:bg-black-100 js-gps-track" data-gps-track="top_nav.products.click({location:5, destination:2})" data-ga="[&quot;top navigation&quot;,&quot;public qa submenu click&quot;,null,null,null]"> <span class="fs-body1 d-block">Stack Overflow</span> <span class="fs-caption d-block fc-light">Public questions &amp; answers</span> </a> </li> <li class="m6"> <a href="/web/20230306154331/https://stackoverflow.com/teams" class="bar-sm p6 d-block h:bg-black-100 js-gps-track" data-gps-track="top_nav.products.click({location:5, destination:3})" data-ga="[&quot;top navigation&quot;,&quot;teams submenu click&quot;,null,null,null]"> <span class="fs-body1 d-block">Stack Overflow for Teams</span> <span class="fs-caption d-block fc-light">Where developers &amp; technologists share private knowledge with coworkers</span> </a> </li> <li class="m6"> <a href="https://web.archive.org/web/20230306154331/https://stackoverflow.co/talent" class="bar-sm p6 d-block h:bg-black-100 js-gps-track" data-gps-track="top_nav.products.click({location:5, destination:5})" data-ga="[&quot;top navigation&quot;,&quot;talent submenu click&quot;,null,null,null]"> <span class="fs-body1 d-block">Talent</span> <span class="fs-caption d-block fc-light"> Build your employer brand </span> </a> </li> <li class="m6"> <a href="https://web.archive.org/web/20230306154331/https://stackoverflow.co/advertising" class="bar-sm p6 d-block h:bg-black-100 js-gps-track" data-gps-track="top_nav.products.click({location:5, destination:6})" data-ga="[&quot;top navigation&quot;,&quot;advertising submenu click&quot;,null,null,null]"> <span class="fs-body1 d-block">Advertising</span> <span class="fs-caption d-block fc-light">Reach developers &amp; technologists worldwide</span> </a> </li> <li class="bg-black-025 bt bc-black-075 py6 px6 bbr-md"> <a href="https://web.archive.org/web/20230306154331/https://stackoverflow.co/" class="fc-light d-block py6 px6 h:fc-black-800 js-gps-track" data-gps-track="top_nav.products.click({location:5, destination:7})" data-ga="[&quot;top navigation&quot;,&quot;about submenu click&quot;,null,null,null]">About the company</a> </li> </ol> </div> <form id="search" role="search" action="/web/20230306154331/https://stackoverflow.com/search" class="s-topbar--searchbar js-searchbar " autocomplete="off"> <div class="s-topbar--searchbar--input-group"> <input name="q" type="text" role="combobox" placeholder="Search…" value="[python]" autocomplete="off" maxlength="240" class="s-input s-input__search js-search-field " aria-label="Search" aria-controls="top-search" data-controller="s-popover" data-action="focus->s-popover#show" data-s-popover-placement="bottom-start"/> <svg aria-hidden="true" class="s-input-icon s-input-icon__search svg-icon iconSearch" width="18" height="18" viewbox="0 0 18 18"><path d="m18 16.5-5.14-5.18h-.35a7 7 0 1 0-1.19 1.19v.35L16.5 18l1.5-1.5ZM12 7A5 5 0 1 1 2 7a5 5 0 0 1 10 0Z"/></svg> <div class="s-popover p0 wmx100 wmn4 sm:wmn-initial js-top-search-popover" id="top-search" role="menu"> <div class="s-popover--arrow"></div> <div class="js-spinner p24 d-flex ai-center jc-center d-none"> <div class="s-spinner s-spinner__sm fc-orange-400"> <div class="v-visible-sr">Loading&#x2026;</div> </div> </div> <span class="v-visible-sr js-screen-reader-info"></span> <div class="js-ac-results overflow-y-auto hmx3 d-none"></div> <div class="js-search-hints" aria-describedby="Tips for searching"></div> </div> </div> </form> <nav class="h100 ml-auto overflow-x-auto pr12"> <ol class="s-topbar--content" role="menubar"> <li class="js-topbar-dialog-corral" role="presentation"> <div class="topbar-dialog siteSwitcher-dialog dno" role="menu"> <div class="header fw-wrap"> <h3 class="flex--item"> <a href="https://web.archive.org/web/20230306154331/https://stackoverflow.com/">current community</a> </h3> <div class="flex--item fl1"> <div class="ai-center d-flex jc-end"> <button class="js-close-button s-btn s-btn__muted p0 ml8 d-none sm:d-block" type="button" aria-label="Close"> <svg aria-hidden="true" class="svg-icon iconClear" width="18" height="18" viewbox="0 0 18 18"><path d="M15 4.41 13.59 3 9 7.59 4.41 3 3 4.41 7.59 9 3 13.59 4.41 15 9 10.41 13.59 15 15 13.59 10.41 9 15 4.41Z"/></svg> </button> </div> </div> </div> <div class="modal-content bg-powder-050 current-site-container"> <ul class="current-site "> <li class="d-flex"> <div class="fl1"> <a href="https://web.archive.org/web/20230306154331/https://stackoverflow.com/" class="current-site-link site-link js-gps-track d-flex gs8 gsx" data-id="1" data-gps-track="site_switcher.click({ item_type:3 })"> <div class="favicon favicon-stackoverflow site-icon flex--item" title="Stack Overflow"></div> <span class="flex--item fl1"> Stack Overflow </span> </a> </div> <div class="related-links"> <a href="https://web.archive.org/web/20230306154331/https://stackoverflow.com/help" class="js-gps-track" data-gps-track="site_switcher.click({ item_type:14 })">help</a> <a href="https://web.archive.org/web/20230306154331/https://chat.stackoverflow.com/?tab=site&amp;host=stackoverflow.com" class="js-gps-track" data-gps-track="site_switcher.click({ item_type:6 })">chat</a> </div> </li> <li class="related-site d-flex"> <div class="L-shaped-icon-container"> <span class="L-shaped-icon"></span> </div> <a href="https://web.archive.org/web/20230306154331/https://meta.stackoverflow.com/" class=" site-link js-gps-track d-flex gs8 gsx" data-id="552" data-gps-track="site.switch({ target_site:552, item_type:3 }),site_switcher.click({ item_type:4 })"> <div class="favicon favicon-stackoverflowmeta site-icon flex--item" title="Meta Stack Overflow"></div> <span class="flex--item fl1"> Meta Stack Overflow </span> </a> </li> </ul> </div> <div class="header" id="your-communities-header"> <h3> your communities </h3> </div> <div class="modal-content" id="your-communities-section"> <div class="call-to-login"> <a href="https://web.archive.org/web/20230306154331/https://stackoverflow.com/users/signup?ssrc=site_switcher&amp;returnurl=https%3a%2f%2fstackoverflow.com%2fquestions%2ftagged%2fpython" class="login-link js-gps-track" data-gps-track="site_switcher.click({ item_type:10 })">Sign up</a> or <a href="https://web.archive.org/web/20230306154331/https://stackoverflow.com/users/login?ssrc=site_switcher&amp;returnurl=https%3a%2f%2fstackoverflow.com%2fquestions%2ftagged%2fpython" class="login-link js-gps-track" data-gps-track="site_switcher.click({ item_type:11 })">log in</a> to customize your list. </div> </div> <div class="header"> <h3><a href="https://web.archive.org/web/20230306154331/https://stackexchange.com/sites">more stack exchange communities</a> </h3> <a href="https://web.archive.org/web/20230306154331/https://stackoverflow.blog/" class="float-right">company blog</a> </div> <div class="modal-content"> <div class="child-content"></div> </div> </div> </li> <li role="none"><button class="s-topbar--item s-btn s-btn__icon s-btn__muted d-none sm:d-inline-flex js-searchbar-trigger" role="menuitem" aria-label="Search" aria-haspopup="true" aria-controls="search" title="Click to show search"><svg aria-hidden="true" class="svg-icon iconSearch" width="18" height="18" viewbox="0 0 18 18"><path d="m18 16.5-5.14-5.18h-.35a7 7 0 1 0-1.19 1.19v.35L16.5 18l1.5-1.5ZM12 7A5 5 0 1 1 2 7a5 5 0 0 1 10 0Z"/></svg></button></li> <li role="none"> <a href="https://web.archive.org/web/20230306154331/https://stackoverflow.com/users/login?ssrc=head&amp;returnurl=https%3a%2f%2fstackoverflow.com%2fquestions%2ftagged%2fpython" class="s-topbar--item s-topbar--item__unset s-btn s-btn__filled ws-nowrap js-gps-track" role="menuitem" rel="nofollow" data-gps-track="login.click" data-ga="[&quot;top navigation&quot;,&quot;login button click&quot;,null,null,null]">Log in</a> </li> <li role="none"><a href="https://web.archive.org/web/20230306154331/https://stackoverflow.com/users/signup?ssrc=head&amp;returnurl=https%3a%2f%2fstackoverflow.com%2fquestions%2ftagged%2fpython" class="s-topbar--item s-topbar--item__unset ml4 s-btn s-btn__primary ws-nowrap" role="menuitem" rel="nofollow" data-ga="[&quot;sign up&quot;,&quot;Sign Up Navigation&quot;,&quot;Header&quot;,null,null]">Sign up</a></li> </ol> </nav> </div> </header> <script> StackExchange.ready(function () { StackExchange.topbar.init(); }); StackExchange.scrollPadding.setPaddingTop(50, 10); </script> <div class="container"> <div id="left-sidebar" data-is-here-when="md lg" class="left-sidebar js-pinned-left-sidebar ps-relative"> <div class="left-sidebar--sticky-container js-sticky-leftnav"> <nav role="navigation"> <ol class="nav-links"> <li class="ps-relative" aria-current="false"> <a href="/web/20230306154331/https://stackoverflow.com/" class="pl8 js-gps-track nav-links--link" data-gps-track="top_nav.click({is_current: false, location:5, destination:8})" aria-controls="" data-controller="" data-s-popover-placement="right" aria-current="false" data-s-popover-auto-show="true" data-s-popover-hide-on-outside-click="never"> <div class="d-flex ai-center"> <div class="flex--item truncate"> Home </div> </div> </a> </li> <li> <ol class="nav-links"> <li class="fs-fine tt-uppercase ml8 mt16 mb4 fc-light">Public</li> <li class="ps-relative youarehere" aria-current="true"> <a id="nav-questions" href="/web/20230306154331/https://stackoverflow.com/questions" class="pl8 js-gps-track nav-links--link -link__with-icon" data-gps-track="top_nav.click({is_current: true, location:5, destination:1})" aria-controls="" data-controller="" data-s-popover-placement="right" aria-current="false" data-s-popover-auto-show="true" data-s-popover-hide-on-outside-click="never"> <svg aria-hidden="true" class="svg-icon iconGlobe" width="18" height="18" viewbox="0 0 18 18"><path d="M9 1C4.64 1 1 4.64 1 9c0 4.36 3.64 8 8 8 4.36 0 8-3.64 8-8 0-4.36-3.64-8-8-8ZM8 15.32a6.46 6.46 0 0 1-4.3-2.74 6.46 6.46 0 0 1-.93-5.01L7 11.68v.8c0 .88.12 1.32 1 1.32v1.52Zm5.72-2c-.2-.66-1-1.32-1.72-1.32h-1v-2c0-.44-.56-1-1-1H6V7h1c.44 0 1-.56 1-1V5h2c.88 0 1.4-.72 1.4-1.6v-.33a6.45 6.45 0 0 1 3.83 4.51 6.45 6.45 0 0 1-1.51 5.73v.01Z"/></svg> <span class="-link--channel-name">Questions</span> </a> </li> <li class="ps-relative" aria-current="false"> <a id="nav-tags" href="/web/20230306154331/https://stackoverflow.com/tags" class=" js-gps-track nav-links--link" data-gps-track="top_nav.click({is_current: false, location:5, destination:2})" aria-controls="" data-controller="" data-s-popover-placement="right" aria-current="false" data-s-popover-auto-show="true" data-s-popover-hide-on-outside-click="never"> <div class="d-flex ai-center"> <div class="flex--item truncate"> Tags </div> </div> </a> </li> <li class="ps-relative" aria-current="false"> <a id="nav-users" href="/web/20230306154331/https://stackoverflow.com/users" class=" js-gps-track nav-links--link" data-gps-track="top_nav.click({is_current: false, location:5, destination:3})" aria-controls="" data-controller="" data-s-popover-placement="right" aria-current="false" data-s-popover-auto-show="true" data-s-popover-hide-on-outside-click="never"> <div class="d-flex ai-center"> <div class="flex--item truncate"> Users </div> </div> </a> </li> <li class="ps-relative" aria-current="false"> <a id="nav-companies" href="https://web.archive.org/web/20230306154331/https://stackoverflow.com/jobs/companies?so_medium=stackoverflow&amp;so_source=SiteNav" class=" js-gps-track nav-links--link" data-gps-track="top_nav.click({is_current: false, location:5, destination:12})" aria-controls="" data-controller="" data-s-popover-placement="right" aria-current="false" data-s-popover-auto-show="true" data-s-popover-hide-on-outside-click="never"> <div class="d-flex ai-center"> <div class="flex--item truncate"> Companies </div> </div> </a> </li> <li class="ml8 mt16"> <div class="d-flex jc-space-between fl-grow1"> <div class="flex--item tt-uppercase tt-uppercase fs-fine fc-light">Collectives</div> <div class="flex--item fs-fine fc-light"> <a href="javascript:void(0)" class="s-link p12 fc-black-500 h:fc-black-800 js-gps-track js-collectives-navcta-toggle" role="button" aria-controls="popover-discover-collectives" data-controller="s-popover" data-action="s-popover#toggle" data-s-popover-placement="top" data-s-popover-toggle-class="is-selected" data-gps-track="top_nav.click({is_current:false, location:5, destination:17})"> <svg aria-hidden="true" class="svg-icon iconInfoSm" width="14" height="14" viewbox="0 0 14 14"><path d="M7 1a6 6 0 1 1 0 12A6 6 0 0 1 7 1Zm1 10V6H6v5h2Zm0-6V3H6v2h2Z"/></svg> </a> </div> </div> </li> <li class="ps-relative" aria-current="false"> <a id="nav-collective-discover" href="/web/20230306154331/https://stackoverflow.com/collectives" class="pl8 ai-center js-collectives-navcta-toggle js-gps-track nav-links--link -link__with-icon" data-gps-track="top_nav.click({is_current: false, location:5, destination:18})" aria-controls="" data-controller="" data-s-popover-placement="right" aria-current="false" data-s-popover-auto-show="true" data-s-popover-hide-on-outside-click="never"> <svg aria-hidden="true" class="mt-auto fc-orange-400 svg-icon iconStarVerified" width="18" height="18" viewbox="0 0 18 18"><path d="M9.86.89a1.14 1.14 0 0 0-1.72 0l-.5.58c-.3.35-.79.48-1.23.33l-.72-.25a1.14 1.14 0 0 0-1.49.85l-.14.76c-.1.45-.45.8-.9.9l-.76.14c-.67.14-1.08.83-.85 1.49l.25.72c.15.44.02.92-.33 1.23l-.58.5a1.14 1.14 0 0 0 0 1.72l.58.5c.35.3.48.79.33 1.23l-.25.72c-.23.66.18 1.35.85 1.49l.76.14c.45.1.8.45.9.9l.14.76c.14.67.83 1.08 1.49.85l.72-.25c.44-.15.92-.02 1.23.33l.5.58c.46.52 1.26.52 1.72 0l.5-.58c.3-.35.79-.48 1.23-.33l.72.25c.66.23 1.35-.18 1.49-.85l.14-.76c.1-.45.45-.8.9-.9l.76-.14c.67-.14 1.08-.83.85-1.49l-.25-.72c-.15-.44-.02-.92.33-1.23l.58-.5c.52-.46.52-1.26 0-1.72l-.58-.5c-.35-.3-.48-.79-.33-1.23l.25-.72a1.14 1.14 0 0 0-.85-1.49l-.76-.14c-.45-.1-.8-.45-.9-.9l-.14-.76a1.14 1.14 0 0 0-1.49-.85l-.72.25c-.44.15-.92.02-1.23-.33l-.5-.58Zm-.49 2.67L10.6 6.6c.05.15.19.24.34.25l3.26.22c.36.03.5.48.23.71l-2.5 2.1a.4.4 0 0 0-.14.4l.8 3.16a.4.4 0 0 1-.6.44L9.2 12.13a.4.4 0 0 0-.42 0l-2.77 1.74a.4.4 0 0 1-.6-.44l.8-3.16a.4.4 0 0 0-.13-.4l-2.5-2.1a.4.4 0 0 1 .22-.7l3.26-.23a.4.4 0 0 0 .34-.25l1.22-3.03a.4.4 0 0 1 .74 0Z"/></svg> <span class="-link--channel-name">Explore Collectives</span> </a> </li> </ol> </li> <li> <ol class="nav-links"> <li class="js-freemium-cta ps-relative"> <div class="fs-fine tt-uppercase ml8 mt16 mb8 fc-light">Teams</div> <div class="bt bl bb bc-black-075 p12 pb6 fc-black-600 blr-sm overflow-hidden"> <strong class="fc-black-750 mb6">Stack Overflow for Teams</strong> – Start collaborating and sharing organizational knowledge. <img class="wmx100 mx-auto my8 h-auto d-block" width="139" height="114" src="https://web.archive.org/web/20230306154331im_/https://cdn.sstatic.net/Img/teams/teams-illo-free-sidebar-promo.svg?v=47faa659a05e" alt=""> <a href="https://web.archive.org/web/20230306154331/https://try.stackoverflow.co/why-teams/?utm_source=so-owned&amp;utm_medium=side-bar&amp;utm_campaign=campaign-38&amp;utm_content=cta" class="w100 s-btn s-btn__primary s-btn__xs bg-orange-400 js-gps-track" data-gps-track="teams.create.left-sidenav.click({ Action: 6 })" data-ga="[&quot;teams left navigation - anonymous&quot;,&quot;left nav free cta&quot;,&quot;stackoverflow.com/teams/create/free&quot;,null,null]">Create a free Team</a> <a href="https://web.archive.org/web/20230306154331/https://stackoverflow.co/teams" class="w100 s-btn s-btn__muted s-btn__xs js-gps-track" data-gps-track="teams.create.left-sidenav.click({ Action: 5 })" data-ga="[&quot;teams left navigation - anonymous&quot;,&quot;left nav free cta&quot;,&quot;stackoverflow.com/teams&quot;,null,null]">Why Teams?</a> </div> </li> <li class="d-flex ai-center jc-space-between ml8 mt24 mb4 js-create-team-cta d-none"> <div class="flex--item tt-uppercase fs-fine fc-light">Teams</div> <div class="flex--item"> <a href="javascript:void(0)" class="s-link p12 fc-black-500 h:fc-black-800 js-gps-track" role="button" aria-controls="popover-teams-create-cta" data-controller="s-popover" data-action="s-popover#toggle" data-s-popover-placement="bottom-start" data-s-popover-toggle-class="is-selected" data-gps-track="teams.create.left-sidenav.click({ Action: ShowInfo })" data-ga="[&quot;teams left navigation - anonymous&quot;,&quot;left nav show teams info&quot;,null,null,null]"> <svg aria-hidden="true" class="svg-icon iconInfoSm" width="14" height="14" viewbox="0 0 14 14"><path d="M7 1a6 6 0 1 1 0 12A6 6 0 0 1 7 1Zm1 10V6H6v5h2Zm0-6V3H6v2h2Z"/></svg> </a> </div> </li> <li class="ps-relative js-create-team-cta d-none"> <a href="https://web.archive.org/web/20230306154331/https://stackoverflowteams.com/teams/create/free?utm_source=so-owned&amp;utm_medium=side-bar&amp;utm_campaign=campaign-38&amp;utm_content=cta" class="pl8 js-gps-track nav-links--link" title="Stack Overflow for Teams is a private, secure spot for your organization's questions and answers." data-gps-track="teams.create.left-sidenav.click({ Action: FreemiumTeamsCreateClick })" data-ga="[&quot;teams left navigation - anonymous&quot;,&quot;left nav team click&quot;,&quot;stackoverflow.com/teams/create/free&quot;,null,null]"> <div class="d-flex ai-center"> <div class="flex--item s-avatar va-middle bg-orange-400"> <div class="s-avatar--letter mtn1"> <svg aria-hidden="true" class="svg-icon iconBriefcaseSm" width="14" height="14" viewbox="0 0 14 14"><path d="M4 3a1 1 0 0 1 1-1h4a1 1 0 0 1 1 1v1h.5c.83 0 1.5.67 1.5 1.5v5c0 .83-.67 1.5-1.5 1.5h-7A1.5 1.5 0 0 1 2 10.5v-5C2 4.67 2.67 4 3.5 4H4V3Zm5 1V3H5v1h4Z"/></svg> </div> <svg aria-hidden="true" class="native s-avatar--badge svg-icon iconShieldXSm" width="9" height="10" viewbox="0 0 9 10"><path fill="var(--white)" d="M0 1.84 4.5 0 9 1.84v3.17C9 7.53 6.3 10 4.5 10 2.7 10 0 7.53 0 5.01V1.84Z"/><path fill="var(--black-500)" d="M1 2.5 4.5 1 8 2.5v2.51C8 7.34 5.34 9 4.5 9 3.65 9 1 7.34 1 5.01V2.5Zm2.98 3.02L3.2 7h2.6l-.78-1.48a.4.4 0 0 1 .15-.38c.34-.24.73-.7.73-1.14 0-.71-.5-1.23-1.41-1.23-.92 0-1.39.52-1.39 1.23 0 .44.4.9.73 1.14.12.08.18.23.15.38Z"/></svg> </div> <div class="flex--item pl6"> Create free Team </div> </div> </a> </li> </ol> </li> </ol> </nav> </div> <div class="s-popover ws2" id="popover-discover-collectives" role="menu"> <div class="s-popover--arrow"></div> <div> <svg aria-hidden="true" class="fc-orange-500 float-right ml24 svg-spot spotCollective" width="48" height="48" viewbox="0 0 48 48"><path d="M25.5 7a2.5 2.5 0 1 0 0-5 2.5 2.5 0 0 0 0 5ZM14 18.25c0-.69.56-1.25 1.25-1.25h22.5c.69 0 1.25.56 1.25 1.25V37.5a1 1 0 0 1-1.6.8l-4.07-3.05a1.25 1.25 0 0 0-.75-.25H15.25c-.69 0-1.25-.56-1.25-1.25v-15.5ZM7 24.5a2.5 2.5 0 1 1-5 0 2.5 2.5 0 0 1 5 0ZM25.5 48a2.5 2.5 0 1 0 0-5 2.5 2.5 0 0 0 0 5ZM48 24.5a2.5 2.5 0 1 1-5 0 2.5 2.5 0 0 1 5 0Z" opacity=".2"/><path d="M21 3.5a3.5 3.5 0 1 1 7 0 3.5 3.5 0 0 1-7 0ZM24.5 2a1.5 1.5 0 1 0 0 3 1.5 1.5 0 0 0 0-3ZM0 23.5a3.5 3.5 0 1 1 7 0 3.5 3.5 0 0 1-7 0ZM3.5 22a1.5 1.5 0 1 0 0 3 1.5 1.5 0 0 0 0-3ZM21 44.5a3.5 3.5 0 1 1 7 0 3.5 3.5 0 0 1-7 0Zm3.5-1.5a1.5 1.5 0 1 0 0 3 1.5 1.5 0 0 0 0-3Zm20-23a3.5 3.5 0 1 0 0 7 3.5 3.5 0 0 0 0-7ZM43 23.5a1.5 1.5 0 1 1 3 0 1.5 1.5 0 0 1-3 0Zm-23.23-3.14a1 1 0 0 1-.13 1.4l-2.08 1.74 2.08 1.73a1 1 0 1 1-1.28 1.54l-2.42-2.02a1.63 1.63 0 0 1 0-2.5l2.42-2.02a1 1 0 0 1 1.4.13Zm7.59 1.41a1 1 0 1 1 1.28-1.54l2.42 2.02c.78.65.78 1.85 0 2.5l-2.42 2.02a1 1 0 1 1-1.28-1.54l2.08-1.73-2.08-1.73ZM24.12 18a1 1 0 0 1 .87 1.12l-1 8a1 1 0 1 1-1.98-.24l1-8a1 1 0 0 1 1.11-.87Zm-11.87-5C11.01 13 10 14 10 15.25v15.5c0 1.24 1 2.25 2.25 2.25h17.33c.06 0 .11.02.15.05l4.07 3.05a2 2 0 0 0 3.2-1.6V15.25c0-1.24-1-2.25-2.25-2.25h-22.5ZM12 15.25c0-.14.11-.25.25-.25h22.5c.14 0 .25.11.25.25V34.5l-4.07-3.05a2.2 2.2 0 0 0-1.35-.45H12.25a.25.25 0 0 1-.25-.25v-15.5Zm7.24-10.68a1 1 0 1 0-.48-1.94A22.04 22.04 0 0 0 2.91 17.7a1 1 0 1 0 1.92.58 20.04 20.04 0 0 1 14.4-13.72Zm11.05-1.66a1 1 0 0 0-.58 1.92c6.45 1.92 11.54 7 13.46 13.46a1 1 0 1 0 1.92-.58 22.05 22.05 0 0 0-14.8-14.8ZM4.57 28.76a1 1 0 0 0-1.94.48 22.03 22.03 0 0 0 16.13 16.13 1 1 0 1 0 .48-1.94A20.03 20.03 0 0 1 4.57 28.76Zm40.8.48a1 1 0 1 0-1.94-.48 20.04 20.04 0 0 1-13.72 14.41 1 1 0 0 0 .58 1.92 22.04 22.04 0 0 0 15.08-15.85Z"/></svg> <h5 class="pt4 fw-bold">Collectives™ on Stack Overflow</h5> <p class="my16 fs-caption fc-medium">Find centralized, trusted content and collaborate around the technologies you use most.</p> <a href="/web/20230306154331/https://stackoverflow.com/collectives" class="js-gps-track s-btn s-btn__primary s-btn__xs" data-gps-track="top_nav.click({is_current:false, location:5, destination:18})"> Learn more about Collectives </a> </div> </div> <div class="s-popover ws2" id="popover-teams-create-cta" role="menu" aria-hidden="true"> <div class="s-popover--arrow"></div> <div class="ps-relative overflow-hidden"> <p class="mb2"><strong>Teams</strong></p> <p class="mb12 fs-caption fc-black-400">Q&amp;A for work</p> <p class="mb12 fs-caption fc-medium">Connect and share knowledge within a single location that is structured and easy to search.</p> <a href="https://web.archive.org/web/20230306154331/https://stackoverflow.co/teams" class="js-gps-track s-btn s-btn__primary s-btn__xs" data-gps-track="teams.create.left-sidenav.click({ Action: CtaClick })" data-ga="[&quot;teams left navigation - anonymous&quot;,&quot;left nav cta&quot;,&quot;stackoverflow.com/teams&quot;,null,null]"> Learn more about Teams </a> </div> <div class="ps-absolute t8 r8"> <svg aria-hidden="true" class="fc-orange-500 svg-spot spotPeople" width="48" height="48" viewbox="0 0 48 48"><path d="M13.5 28a4.5 4.5 0 1 0 0-9 4.5 4.5 0 0 0 0 9ZM7 30a1 1 0 0 1 1-1h11a1 1 0 0 1 1 1v5h11v-5a1 1 0 0 1 1-1h12a1 1 0 0 1 1 1v10a2 2 0 0 1-2 2H33v5a1 1 0 0 1-1 1H20a1 1 0 0 1-1-1v-5H8a1 1 0 0 1-1-1V30Zm25-6.5a4.5 4.5 0 1 0 9 0 4.5 4.5 0 0 0-9 0ZM24.5 34a4.5 4.5 0 1 0 0-9 4.5 4.5 0 0 0 0 9Z" opacity=".2"/><path d="M16.4 26.08A6 6 0 1 0 7.53 26C5.64 26.06 4 27.52 4 29.45V40a1 1 0 0 0 1 1h9a1 1 0 1 0 0-2h-4v-7a1 1 0 1 0-2 0v7H6v-9.55c0-.73.67-1.45 1.64-1.45H16a1 1 0 0 0 .4-1.92ZM12 18a4 4 0 1 1 0 8 4 4 0 0 1 0-8Zm16.47 14a6 6 0 1 0-8.94 0A3.6 3.6 0 0 0 16 35.5V46a1 1 0 0 0 1 1h14a1 1 0 0 0 1-1V35.5c0-1.94-1.64-3.42-3.53-3.5ZM20 28a4 4 0 1 1 8 0 4 4 0 0 1-8 0Zm-.3 6h8.6c1 0 1.7.75 1.7 1.5V45h-2v-7a1 1 0 1 0-2 0v7h-4v-7a1 1 0 1 0-2 0v7h-2v-9.5c0-.75.7-1.5 1.7-1.5ZM42 22c0 1.54-.58 2.94-1.53 4A3.5 3.5 0 0 1 44 29.45V40a1 1 0 0 1-1 1h-9a1 1 0 1 1 0-2h4v-7a1 1 0 1 1 2 0v7h2v-9.55A1.5 1.5 0 0 0 40.48 28H32a1 1 0 0 1-.4-1.92A6 6 0 1 1 42 22Zm-2 0a4 4 0 1 0-8 0 4 4 0 0 0 8 0Z"/><g opacity=".35"><path d="M17 10a1 1 0 011-1h12a1 1 0 110 2H18a1 1 0 01-1-1Zm1-5a1 1 0 100 2h12a1 1 0 100-2H18ZM14 1a1 1 0 00-1 1v12a1 1 0 001 1h5.09l4.2 4.2a1 1 0 001.46-.04l3.7-4.16H34a1 1 0 001-1V2a1 1 0 00-1-1H14Zm1 12V3h18v10h-5a1 1 0 00-.75.34l-3.3 3.7-3.74-3.75a1 1 0 00-.71-.29H15Z"/></g></svg> </div> </div> </div> <div id="content" class="snippet-hidden"> <div id="mainbar"> <div class="d-flex"> <div class="d-flex fl1 mb24"> <h1 class="flex--item fs-headline1 mb0"> Questions tagged [python] </h1> </div> <div class="ml12 aside-cta flex--item print:d-none"> <a href="/web/20230306154331/https://stackoverflow.com/questions/ask" class="ws-nowrap s-btn s-btn__primary"> Ask Question </a> </div> </div> <style> </style> <div class="js-zone-container zone-container-main"> <div id="dfp-tag" class="everyonelovesstackoverflow everyoneloves__tag-sponsorship theme-light__forced bg-white"></div> <div class="js-report-ad-button-container " style="width: 728px"></div> </div> <div class="mb24"> <p> Python is a multi-paradigm, dynamically typed, multi-purpose programming language. It is designed to be quick to learn, understand, and use, and enforces a clean and uniform syntax. Please note that Python 2 is officially out of support as of 2020-01-01. For version-specific Python questions, add the [python-2.7] or [python-3.x] tag. When using a Python variant (e.g. Jython, PyPy) or library (e.g. Pandas, NumPy), please include it in the tags. </p> <div class=" d-flex gs12 jc-space-between ai-center fw-wrap"> <div class="flex--item"> <ul class="d-flex gs12 list-ls-none fw-wrap"> <li class="flex--item"> <a title="Tag wiki" href="/web/20230306154331/https://stackoverflow.com/tags/python/info">Learn more…</a> </li> <li class="flex--item"> <a title="Top answerers and askers in this tag" href="/web/20230306154331/https://stackoverflow.com/tags/python/topusers">Top users</a> </li> <li class="flex--item"> <a title="Common, alternate spellings or phrasings for this tag" href="/web/20230306154331/https://stackoverflow.com/tags/python/synonyms">Synonyms (4)</a> </li> </ul> </div> </div> </div> <script type="application/json" data-role="module-args" data-module-name="entry-points/questions/userQuestionList.mod">{"regularTagsString":"","moderatorTagsString":""}</script> <script defer src="https://web.archive.org/web/20230306154331js_/https://cdn.sstatic.net/Js/questions/userQuestionList.en.js?v=9e054838afaa"></script> <div data-controller="se-uql" data-se-uql-id="" data-se-uql-sanitize-tag-query="false"> <div class="d-flex ai-center jc-space-between mb12 sm:fd-column sm:ai-stretch"> <div class="fs-body3 flex--item fl1 mr12 sm:mr0 sm:mb12"> 2,115,703 questions </div> <div class="uql-nav flex--item" data-action="se-uql-list:edit-current-requested@document->se-uql#toggleEditor"> <div class="d-flex ai-center jc-space-between"> <div class="js-uql-navigation s-btn-group flex--item mr16 ff-row-nowrap"> <a class="s-btn s-btn__muted s-btn__outlined s-btn__sm d-flex" data-nav-value="Newest" href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python?tab=Newest" data-shortcut="N"> <div class="flex--item">Newest</div> </a> <a class="s-btn s-btn__muted s-btn__outlined s-btn__sm d-flex" data-nav-value="Active" href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python?tab=Active" data-shortcut="A"> <div class="flex--item">Active</div> </a> <a class="s-btn s-btn__muted s-btn__outlined s-btn__sm d-flex uql-nav--expanded-item" data-nav-value="Bounties" href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python?tab=Bounties" data-shortcut="E"> <div class="flex--item">Bountied</div> <div class="s-badge s-badge__bounty s-badge__bounty s-badge__sm lh-xs ml4 px4 flex--item">23</div> </a> <a class="s-btn s-btn__muted s-btn__outlined s-btn__sm d-flex uql-nav--expanded-item" data-nav-value="Unanswered" href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python?tab=Unanswered" data-shortcut="U"> <div class="flex--item">Unanswered</div> </a> <button class="s-btn s-btn__muted s-btn__outlined s-btn__sm s-btn__dropdown is-selected" role="button" data-controller="s-popover" data-action="s-popover#toggle" data-se-uql-target="toggleMoreButton" aria-haspopup="true" aria-expanded="false" aria-controls="uql-more-popover"> More </button> </div> <div class="s-popover z-dropdown ws2 px0 py4" id="uql-more-popover" data-se-uql-target="morePopover"> <div class="s-popover--arrow"></div> <ul class="s-menu js-uql-navigation" role="menu"> <li class=" uql-nav--collapsed-item" role="menuitem"> <a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python?tab=Bounties" class="s-block-link s-block-link__left" data-shortcut=""> Bountied <span class="s-badge s-badge__bounty s-badge__bounty s-badge__sm lh-xs px4">23</span> </a> </li> <li class=" uql-nav--collapsed-item" role="menuitem"> <a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python?tab=Unanswered" class="s-block-link s-block-link__left" data-shortcut=""> Unanswered </a> </li> <li role="menuitem"> <a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python?tab=Frequent" class="s-block-link s-block-link__left" data-shortcut="F"> Frequent </a> </li> <li role="menuitem"> <a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python?tab=Votes" class="s-block-link s-block-link__left is-selected" aria-current="page" data-shortcut="V"> Score </a> </li> <li class="s-menu--divider" role="separator"></li> <li role="menuitem"> <span class="s-block-link c-default fc-black-350">Unanswered (my tags)</span> </li> </ul> </div> <div class="flex--item"> <button class="s-btn s-btn__filled s-btn__sm s-btn__icon ws-nowrap" role="button" data-controller="s-expandable-control" data-s-expandable-control-toggle-class="is-selected" data-se-uql-target="toggleFormButton" aria-expanded="false" aria-controls="uql-form"> <svg aria-hidden="true" class="svg-icon iconFilter" width="18" height="18" viewbox="0 0 18 18"><path d="M2 4h14v2H2V4Zm2 4h10v2H4V8Zm8 4H6v2h6v-2Z"/></svg> Filter </button> </div> </div> </div> </div> <form class="s-expandable ps-relative z-active" id="uql-form" data-se-uql-target="form" data-action="se-uql#navigate"> <input name="uqlId" type="hidden"/> <div class="s-expandable--content"> <div class="bg-black-050 ba bc-black-100 bar-sm mb16"> <div class="px12 py16"> <div class="d-flex gs32 fw-wrap"> <div class="flex--item"> <fieldset class="d-flex gs8 gsy fd-column"> <legend class="flex--item s-label px0">Filter by</legend> <div class="flex--item"> <div class="d-flex gs4 gsx ai-center"> <div class="flex--item"> <input class="s-checkbox d-block" type="checkbox" name="filterId" value="NoAnswers" id="9f4e2e2f-3fb2-4c7c-a7b5-8f547dd9ca21"/> </div> <label class="flex--item s-label fw-normal ws-nowrap" for="9f4e2e2f-3fb2-4c7c-a7b5-8f547dd9ca21" id="3f58db7c-eb1e-4bb4-87db-cbfc57d0480c">No answers</label> </div> </div> <div class="flex--item"> <div class="d-flex gs4 gsx ai-center"> <div class="flex--item"> <input class="s-checkbox d-block" type="checkbox" name="filterId" value="NoAcceptedAnswer" id="ce44fb0a-b1b2-45b8-b8a5-7011810ada5b"/> </div> <label class="flex--item s-label fw-normal ws-nowrap" for="ce44fb0a-b1b2-45b8-b8a5-7011810ada5b" id="775c0479-d1e9-4917-9f28-146d65102507">No accepted answer</label> </div> </div> <div class="flex--item"> <div class="d-flex gs4 gsx ai-center"> <div class="flex--item"> <input class="s-checkbox d-block" type="checkbox" name="filterId" value="Bounty" id="4b89915b-f641-468a-88f7-44a642eea012"/> </div> <label class="flex--item s-label fw-normal ws-nowrap" for="4b89915b-f641-468a-88f7-44a642eea012" id="dabbfc04-ea75-4c5a-ae26-302bea99e445">Has bounty</label> </div> </div> </fieldset> </div> <div class="flex--item"> <fieldset class="d-flex gs8 gsy fd-column"> <legend class="flex--item s-label px0">Sorted by</legend> <div class="flex--item"> <div class="d-flex gs4 gsx ai-center"> <div class="flex--item"> <input class="s-radio d-block" type="radio" name="sortId" value="Newest" id="ea884d28-c063-4c73-8baf-6e3de179ecb0"/> </div> <label class="flex--item s-label fw-normal ws-nowrap" for="ea884d28-c063-4c73-8baf-6e3de179ecb0" id="c032866d-067b-4b08-a565-6c4f654b2ee1">Newest</label> </div> </div> <div class="flex--item"> <div class="d-flex gs4 gsx ai-center"> <div class="flex--item"> <input class="s-radio d-block" type="radio" name="sortId" value="RecentActivity" id="137d1944-b45e-4e39-ae3d-8d86ea3707c7"/> </div> <label class="flex--item s-label fw-normal ws-nowrap" for="137d1944-b45e-4e39-ae3d-8d86ea3707c7" id="e75c93d2-8949-4a3b-a08e-0dbc740462a6">Recent activity</label> </div> </div> <div class="flex--item"> <div class="d-flex gs4 gsx ai-center"> <div class="flex--item"> <input class="s-radio d-block" type="radio" name="sortId" value="MostVotes" checked="checked" id="e2c9ddad-ce4b-465c-be91-ef627677028c"/> </div> <label class="flex--item s-label fw-normal ws-nowrap" for="e2c9ddad-ce4b-465c-be91-ef627677028c" id="1d24e193-0fcd-4d62-b2e5-00d4cede64df">Highest score</label> </div> </div> <div class="flex--item"> <div class="d-flex gs4 gsx ai-center"> <div class="flex--item"> <input class="s-radio d-block" type="radio" name="sortId" value="MostFrequent" id="605c8c3b-1818-41bb-857d-8e2c14941358"/> </div> <label class="flex--item s-label fw-normal ws-nowrap" for="605c8c3b-1818-41bb-857d-8e2c14941358" id="7726ed93-3d70-4193-9d17-b13b9f9f4ab0">Most frequent</label> </div> </div> <div class="flex--item"> <div class="d-flex gs4 gsx ai-center"> <div class="flex--item"> <input class="s-radio d-block" type="radio" name="sortId" value="BountyEndingSoon" id="3822a868-6e0e-4d52-8385-89f943a8e2e1"/> </div> <label class="flex--item s-label fw-normal ws-nowrap" for="3822a868-6e0e-4d52-8385-89f943a8e2e1" id="d0c98157-a28d-4b84-aab3-e17706d5e910">Bounty ending soon</label> </div> </div> </fieldset> </div> <div class="flex--item"> <fieldset class="d-flex gs8 gsy fd-column"> <legend class="flex--item s-label px0">Tagged with</legend> <div class="flex--item"> <div class="d-flex gs4 gsx ai-center"> <div class="flex--item"> <input class="s-radio d-block" type="radio" name="tagModeId" value="Watched" id="5b7304f6-4609-4164-958a-5847475141ab"/> </div> <label class="flex--item s-label fw-normal ws-nowrap" for="5b7304f6-4609-4164-958a-5847475141ab" id="96936805-1280-44ec-965b-88c708a812cf">My watched tags</label> </div> </div> <div class="flex--item"> <div class="d-flex gs4 gsx ai-center"> <div class="flex--item"> <input class="s-radio d-block" type="radio" name="tagModeId" value="Specified" checked="checked" id="24522d68-c34f-4be0-9482-bf8eb213e2db"/> </div> <label class="flex--item s-label fw-normal ws-nowrap" for="24522d68-c34f-4be0-9482-bf8eb213e2db" id="312e1337-19b5-4bbd-a863-1231d7092e15">The following tags:</label> </div> </div> </fieldset> <div class="ps-relative ml24 mt8 ws2"> <input id="uql-modal-tag-input" class="w100 s-input" name="tagQuery" data-se-uql-target="tagQuery" type="text" size="60" tabindex="0" aria-labelledby="312e1337-19b5-4bbd-a863-1231d7092e15" placeholder="e.g. javascript or python" value="python"> </div> </div> </div> </div> <div class="p12 bt bc-black-100"> <div class="d-flex"> <div class="d-flex gs4 gsx fl1"> <button class="s-btn s-btn__sm s-btn__primary flex--item" type="submit" data-se-uql-target="applyButton">Apply filter</button> </div> <div class="flex--item"> <button class="s-btn s-btn__sm" data-action="se-uql#cancelEditor" type="button">Cancel</button> </div> </div> </div> </div> </div> </form> </div> <div id="questions" class=" flush-left"> <div id="question-summary-231767" class="s-post-summary js-post-summary" data-post-id="231767" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 12521"> <span class="s-post-summary--stats-item-number">12521</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">51</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="3151964 views"> <span class="s-post-summary--stats-item-number">3.2m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/231767/what-does-the-yield-keyword-do-in-python" class="s-link">What does the &quot;yield&quot; keyword do in Python?</a> </h3> <div class="s-post-summary--content-excerpt"> What is the use of the yield keyword in Python? What does it do? For example, I'm trying to understand this code1: def _get_child_candidates(self, distance, min_dist, max_dist): if self._leftchild ... </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-iterator t-generator"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/iterator" class="post-tag flex--item mt0 js-tagname-iterator" title="show questions tagged 'iterator'" aria-label="show questions tagged 'iterator'" rel="tag" aria-labelledby="tag-iterator-tooltip-container">iterator</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/generator" class="post-tag flex--item mt0 js-tagname-generator" title="show questions tagged 'generator'" aria-label="show questions tagged 'generator'" rel="tag" aria-labelledby="tag-generator-tooltip-container">generator</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/18300/alex-s" class="s-avatar s-avatar__16 s-user-card--avatar js-user-hover-target" data-user-id="18300"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://i.stack.imgur.com/jcyI4.jpg?s=32&amp;g=1" alt="Alex. S.'s user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/18300/alex-s" class="flex--item">Alex. S.</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 141,212" dir="ltr">141k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2008-10-23 22:21:11Z" class="relativetime">Oct 23, 2008 at 22:21</span></time> </div> </div> </div> </div> <div id="question-summary-419163" class="s-post-summary js-post-summary" data-post-id="419163" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 7940"> <span class="s-post-summary--stats-item-number">7940</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">45</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="4362274 views"> <span class="s-post-summary--stats-item-number">4.4m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/419163/what-does-if-name-main-do" class="s-link">What does if __name__ == &quot;__main__&quot;: do?</a> </h3> <div class="s-post-summary--content-excerpt"> What does this do, and why should one include the if statement? if __name__ == &quot;__main__&quot;: print(&quot;Hello, World!&quot;) If you are trying to close a question where someone should be ... </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-namespaces t-program-entry-point t-python-module t-idioms"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/namespaces" class="post-tag flex--item mt0 js-tagname-namespaces" title="show questions tagged 'namespaces'" aria-label="show questions tagged 'namespaces'" rel="tag" aria-labelledby="tag-namespaces-tooltip-container">namespaces</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/program-entry-point" class="post-tag flex--item mt0 js-tagname-program-entry-point" title="show questions tagged 'program-entry-point'" aria-label="show questions tagged 'program-entry-point'" rel="tag" aria-labelledby="tag-program-entry-point-tooltip-container">program-entry-point</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python-module" class="post-tag flex--item mt0 js-tagname-python-module" title="show questions tagged 'python-module'" aria-label="show questions tagged 'python-module'" rel="tag" aria-labelledby="tag-python-module-tooltip-container">python-module</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/idioms" class="post-tag flex--item mt0 js-tagname-idioms" title="show questions tagged 'idioms'" aria-label="show questions tagged 'idioms'" rel="tag" aria-labelledby="tag-idioms-tooltip-container">idioms</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/51518/devoted" class="s-avatar s-avatar__16 s-user-card--avatar" data-user-id="51518"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/eb5a95cb1be342c4089183cd8232a7f2?s=32&amp;d=identicon&amp;r=PG" alt="Devoted's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/51518/devoted" class="flex--item">Devoted</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 175,019" dir="ltr">175k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2009-01-07 04:11:00Z" class="relativetime">Jan 7, 2009 at 4:11</span></time> </div> </div> </div> </div> <div id="question-summary-394809" class="s-post-summary js-post-summary" data-post-id="394809" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 7651"> <span class="s-post-summary--stats-item-number">7651</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">31</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="2713184 views"> <span class="s-post-summary--stats-item-number">2.7m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/394809/does-python-have-a-ternary-conditional-operator" class="s-link">Does Python have a ternary conditional operator?</a> </h3> <div class="s-post-summary--content-excerpt"> Is there a ternary conditional operator in Python? </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-operators t-conditional-operator"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/operators" class="post-tag flex--item mt0 js-tagname-operators" title="show questions tagged 'operators'" aria-label="show questions tagged 'operators'" rel="tag" aria-labelledby="tag-operators-tooltip-container">operators</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/conditional-operator" class="post-tag flex--item mt0 js-tagname-conditional-operator" title="show questions tagged 'conditional-operator'" aria-label="show questions tagged 'conditional-operator'" rel="tag" aria-labelledby="tag-conditional-operator-tooltip-container">conditional-operator</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/51518/devoted" class="s-avatar s-avatar__16 s-user-card--avatar" data-user-id="51518"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/eb5a95cb1be342c4089183cd8232a7f2?s=32&amp;d=identicon&amp;r=PG" alt="Devoted's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/51518/devoted" class="flex--item">Devoted</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 175,019" dir="ltr">175k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2008-12-27 08:32:18Z" class="relativetime">Dec 27, 2008 at 8:32</span></time> </div> </div> </div> </div> <div id="question-summary-100003" class="s-post-summary js-post-summary" data-post-id="100003" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 7144"> <span class="s-post-summary--stats-item-number">7144</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">25</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="1093941 views"> <span class="s-post-summary--stats-item-number">1.1m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/100003/what-are-metaclasses-in-python" class="s-link">What are metaclasses in Python?</a> </h3> <div class="s-post-summary--content-excerpt"> What are metaclasses? What are they used for? </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-oop t-metaclass t-python-class t-python-datamodel"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/oop" class="post-tag flex--item mt0 js-tagname-oop" title="show questions tagged 'oop'" aria-label="show questions tagged 'oop'" rel="tag" aria-labelledby="tag-oop-tooltip-container">oop</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/metaclass" class="post-tag flex--item mt0 js-tagname-metaclass" title="show questions tagged 'metaclass'" aria-label="show questions tagged 'metaclass'" rel="tag" aria-labelledby="tag-metaclass-tooltip-container">metaclass</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python-class" class="post-tag flex--item mt0 js-tagname-python-class" title="show questions tagged 'python-class'" aria-label="show questions tagged 'python-class'" rel="tag" aria-labelledby="tag-python-class-tooltip-container">python-class</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python-datamodel" class="post-tag flex--item mt0 js-tagname-python-datamodel" title="show questions tagged 'python-datamodel'" aria-label="show questions tagged 'python-datamodel'" rel="tag" aria-labelledby="tag-python-datamodel-tooltip-container">python-datamodel</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/9951/e-satis" class="s-avatar s-avatar__16 s-user-card--avatar js-user-hover-target" data-user-id="9951"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/?s=32&amp;d=identicon&amp;r=PG&amp;f=1" alt="e-satis's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/9951/e-satis" class="flex--item">e-satis</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 570,825" dir="ltr">571k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2008-09-19 06:10:46Z" class="relativetime">Sep 19, 2008 at 6:10</span></time> </div> </div> </div> </div> <div id="question-summary-82831" class="s-post-summary js-post-summary" data-post-id="82831" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 6915"> <span class="s-post-summary--stats-item-number">6915</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers " title="40 answers"> <span class="s-post-summary--stats-item-number">40</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="5128344 views"> <span class="s-post-summary--stats-item-number">5.1m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/82831/how-do-i-check-whether-a-file-exists-without-exceptions" class="s-link">How do I check whether a file exists without exceptions?</a> </h3> <div class="s-post-summary--content-excerpt"> How do I check whether a file exists or not, without using the try statement? </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-file t-file-exists"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/file" class="post-tag flex--item mt0 js-tagname-file" title="show questions tagged 'file'" aria-label="show questions tagged 'file'" rel="tag" aria-labelledby="tag-file-tooltip-container">file</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/file-exists" class="post-tag flex--item mt0 js-tagname-file-exists" title="show questions tagged 'file-exists'" aria-label="show questions tagged 'file-exists'" rel="tag" aria-labelledby="tag-file-exists-tooltip-container">file-exists</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/15616/spence91" class="s-avatar s-avatar__16 s-user-card--avatar" data-user-id="15616"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/1d502f7932af0a41d8ff6ab5d9cf3406?s=32&amp;d=identicon&amp;r=PG" alt="spence91's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/15616/spence91" class="flex--item">spence91</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 75,967" dir="ltr">76k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2008-09-17 12:55:00Z" class="relativetime">Sep 17, 2008 at 12:55</span></time> </div> </div> </div> </div> <div id="question-summary-38987" class="s-post-summary js-post-summary" data-post-id="38987" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 6640"> <span class="s-post-summary--stats-item-number">6640</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">43</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="3019210 views"> <span class="s-post-summary--stats-item-number">3.0m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/38987/how-do-i-merge-two-dictionaries-in-a-single-expression-in-python" class="s-link">How do I merge two dictionaries in a single expression in Python?</a> </h3> <div class="s-post-summary--content-excerpt"> I want to merge two dictionaries into a new dictionary. x = {'a': 1, 'b': 2} y = {'b': 3, 'c': 4} z = merge(x, y) &gt;&gt;&gt; z {'a': 1, 'b': 3, 'c': 4} Whenever a key k is present in both ... </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-dictionary t-merge"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/dictionary" class="post-tag flex--item mt0 js-tagname-dictionary" title="show questions tagged 'dictionary'" aria-label="show questions tagged 'dictionary'" rel="tag" aria-labelledby="tag-dictionary-tooltip-container">dictionary</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/merge" class="post-tag flex--item mt0 js-tagname-merge" title="show questions tagged 'merge'" aria-label="show questions tagged 'merge'" rel="tag" aria-labelledby="tag-merge-tooltip-container">merge</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/3207/carl-meyer" class="s-avatar s-avatar__16 s-user-card--avatar" data-user-id="3207"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/b1f36e554be0e1ae19f9a74d6ece9107?s=32&amp;d=identicon&amp;r=PG" alt="Carl Meyer's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/3207/carl-meyer" class="flex--item">Carl Meyer</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 119,748" dir="ltr">120k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2008-09-02 07:44:30Z" class="relativetime">Sep 2, 2008 at 7:44</span></time> </div> </div> </div> </div> <div id="question-summary-89228" class="s-post-summary js-post-summary" data-post-id="89228" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 5921"> <span class="s-post-summary--stats-item-number">5921</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">65</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="4281231 views"> <span class="s-post-summary--stats-item-number">4.3m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/89228/how-do-i-execute-a-program-or-call-a-system-command" class="s-link">How do I execute a program or call a system command?</a> </h3> <div class="s-post-summary--content-excerpt"> How do I call an external command within Python as if I had typed it in a shell or command prompt? </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-shell t-terminal t-subprocess t-command"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/shell" class="post-tag flex--item mt0 js-tagname-shell" title="show questions tagged 'shell'" aria-label="show questions tagged 'shell'" rel="tag" aria-labelledby="tag-shell-tooltip-container">shell</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/terminal" class="post-tag flex--item mt0 js-tagname-terminal" title="show questions tagged 'terminal'" aria-label="show questions tagged 'terminal'" rel="tag" aria-labelledby="tag-terminal-tooltip-container">terminal</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/subprocess" class="post-tag flex--item mt0 js-tagname-subprocess" title="show questions tagged 'subprocess'" aria-label="show questions tagged 'subprocess'" rel="tag" aria-labelledby="tag-subprocess-tooltip-container">subprocess</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/command" class="post-tag flex--item mt0 js-tagname-command" title="show questions tagged 'command'" aria-label="show questions tagged 'command'" rel="tag" aria-labelledby="tag-command-tooltip-container">command</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/17085/freshwower" class="s-avatar s-avatar__16 s-user-card--avatar" data-user-id="17085"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/d386a6f2f3dda7bcf7f1e11c2171946b?s=32&amp;d=identicon&amp;r=PG" alt="freshWoWer's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/17085/freshwower" class="flex--item">freshWoWer</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 60,969" dir="ltr">61k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2008-09-18 01:35:30Z" class="relativetime">Sep 18, 2008 at 1:35</span></time> </div> </div> </div> </div> <div id="question-summary-273192" class="s-post-summary js-post-summary" data-post-id="273192" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 5454"> <span class="s-post-summary--stats-item-number">5454</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">28</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="3495064 views"> <span class="s-post-summary--stats-item-number">3.5m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/273192/how-can-i-safely-create-a-directory-possibly-including-intermediate-directories" class="s-link">How can I safely create a directory (possibly including intermediate directories)?</a> </h3> <div class="s-post-summary--content-excerpt"> I am writing a file using Python, and I want it to be placed in a specific path. How can I safely make sure that the path exists? That is: how can I check whether the folder exists, along with its ... </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-exception t-path t-directory t-operating-system"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/exception" class="post-tag flex--item mt0 js-tagname-exception" title="show questions tagged 'exception'" aria-label="show questions tagged 'exception'" rel="tag" aria-labelledby="tag-exception-tooltip-container">exception</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/path" class="post-tag flex--item mt0 js-tagname-path" title="show questions tagged 'path'" aria-label="show questions tagged 'path'" rel="tag" aria-labelledby="tag-path-tooltip-container">path</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/directory" class="post-tag flex--item mt0 js-tagname-directory" title="show questions tagged 'directory'" aria-label="show questions tagged 'directory'" rel="tag" aria-labelledby="tag-directory-tooltip-container">directory</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/operating-system" class="post-tag flex--item mt0 js-tagname-operating-system" title="show questions tagged 'operating-system'" aria-label="show questions tagged 'operating-system'" rel="tag" aria-labelledby="tag-operating-system-tooltip-container">operating-system</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/13055/parand" class="s-avatar s-avatar__16 s-user-card--avatar js-user-hover-target" data-user-id="13055"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/ab82fd8b5ffe4d09c2bb5f9c14d34b09?s=32&amp;d=identicon&amp;r=PG" alt="Parand's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/13055/parand" class="flex--item">Parand</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 101,440" dir="ltr">101k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2008-11-07 18:56:45Z" class="relativetime">Nov 7, 2008 at 18:56</span></time> </div> </div> </div> </div> <div id="question-summary-522563" class="s-post-summary js-post-summary" data-post-id="522563" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 5068"> <span class="s-post-summary--stats-item-number">5068</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">26</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="3780336 views"> <span class="s-post-summary--stats-item-number">3.8m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/522563/accessing-the-index-in-for-loops" class="s-link">Accessing the index in &#39;for&#39; loops</a> </h3> <div class="s-post-summary--content-excerpt"> How do I access the index while iterating over a sequence with a for loop? xs = [8, 23, 45] for x in xs: print(&quot;item #{} = {}&quot;.format(index, x)) Desired output: item #1 = 8 item #2 = ... </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-loops t-list"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/loops" class="post-tag flex--item mt0 js-tagname-loops" title="show questions tagged 'loops'" aria-label="show questions tagged 'loops'" rel="tag" aria-labelledby="tag-loops-tooltip-container">loops</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/list" class="post-tag flex--item mt0 js-tagname-list" title="show questions tagged 'list'" aria-label="show questions tagged 'list'" rel="tag" aria-labelledby="tag-list-tooltip-container">list</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/51816/joan-venge" class="s-avatar s-avatar__16 s-user-card--avatar js-user-hover-target" data-user-id="51816"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/0e54bb28182bcd9df39704751306df27?s=32&amp;d=identicon&amp;r=PG" alt="Joan Venge's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/51816/joan-venge" class="flex--item">Joan Venge</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 308,459" dir="ltr">308k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2009-02-06 22:47:54Z" class="relativetime">Feb 6, 2009 at 22:47</span></time> </div> </div> </div> </div> <div id="question-summary-952914" class="s-post-summary js-post-summary" data-post-id="952914" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 5052"> <span class="s-post-summary--stats-item-number">5052</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">34</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="3855174 views"> <span class="s-post-summary--stats-item-number">3.9m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/952914/how-do-i-make-a-flat-list-out-of-a-list-of-lists" class="s-link">How do I make a flat list out of a list of lists?</a> </h3> <div class="s-post-summary--content-excerpt"> I have a list of lists like [[1, 2, 3], [4, 5, 6], [7], [8, 9]]. How can I flatten it to get [1, 2, 3, 4, 5, 6, 7, 8, 9]? If your list of lists comes from a nested list comprehension, the problem can ... </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-list t-multidimensional-array t-flatten"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/list" class="post-tag flex--item mt0 js-tagname-list" title="show questions tagged 'list'" aria-label="show questions tagged 'list'" rel="tag" aria-labelledby="tag-list-tooltip-container">list</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/multidimensional-array" class="post-tag flex--item mt0 js-tagname-multidimensional-array" title="show questions tagged 'multidimensional-array'" aria-label="show questions tagged 'multidimensional-array'" rel="tag" aria-labelledby="tag-multidimensional-array-tooltip-container">multidimensional-array</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/flatten" class="post-tag flex--item mt0 js-tagname-flatten" title="show questions tagged 'flatten'" aria-label="show questions tagged 'flatten'" rel="tag" aria-labelledby="tag-flatten-tooltip-container">flatten</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/110527/emma" class="s-avatar s-avatar__16 s-user-card--avatar" data-user-id="110527"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/1a3fec384503a3e0b33361f146006598?s=32&amp;d=identicon&amp;r=PG" alt="Emma's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/110527/emma" class="flex--item">Emma</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 51,283" dir="ltr">51.3k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2009-06-04 20:30:05Z" class="relativetime">Jun 4, 2009 at 20:30</span></time> </div> </div> </div> </div> <div id="question-summary-136097" class="s-post-summary js-post-summary" data-post-id="136097" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 4504"> <span class="s-post-summary--stats-item-number">4504</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">35</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="1023968 views"> <span class="s-post-summary--stats-item-number">1.0m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/136097/difference-between-staticmethod-and-classmethod" class="s-link">Difference between @staticmethod and @classmethod</a> </h3> <div class="s-post-summary--content-excerpt"> What is the difference between a method decorated with @staticmethod and one decorated with @classmethod? </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-oop t-methods t-python-decorators"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/oop" class="post-tag flex--item mt0 js-tagname-oop" title="show questions tagged 'oop'" aria-label="show questions tagged 'oop'" rel="tag" aria-labelledby="tag-oop-tooltip-container">oop</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/methods" class="post-tag flex--item mt0 js-tagname-methods" title="show questions tagged 'methods'" aria-label="show questions tagged 'methods'" rel="tag" aria-labelledby="tag-methods-tooltip-container">methods</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python-decorators" class="post-tag flex--item mt0 js-tagname-python-decorators" title="show questions tagged 'python-decorators'" aria-label="show questions tagged 'python-decorators'" rel="tag" aria-labelledby="tag-python-decorators-tooltip-container">python-decorators</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/4766/daryl-spitzer" class="s-avatar s-avatar__16 s-user-card--avatar js-user-hover-target" data-user-id="4766"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/56dbb3799dd6358c3bee3468d0328046?s=32&amp;d=identicon&amp;r=PG" alt="Daryl Spitzer's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/4766/daryl-spitzer" class="flex--item">Daryl Spitzer</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 140,502" dir="ltr">141k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2008-09-25 21:01:57Z" class="relativetime">Sep 25, 2008 at 21:01</span></time> </div> </div> </div> </div> <div id="question-summary-509211" class="s-post-summary js-post-summary" data-post-id="509211" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 4447"> <span class="s-post-summary--stats-item-number">4447</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">38</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="2824472 views"> <span class="s-post-summary--stats-item-number">2.8m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/509211/understanding-slicing" class="s-link">Understanding slicing</a> </h3> <div class="s-post-summary--content-excerpt"> How does Python's slice notation work? That is: when I write code like a[x:y:z], a[:], a[::2] etc., how can I understand which elements end up in the slice? Please include references where appropriate.... </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-slice t-sequence"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/slice" class="post-tag flex--item mt0 js-tagname-slice" title="show questions tagged 'slice'" aria-label="show questions tagged 'slice'" rel="tag" aria-labelledby="tag-slice-tooltip-container">slice</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/sequence" class="post-tag flex--item mt0 js-tagname-sequence" title="show questions tagged 'sequence'" aria-label="show questions tagged 'sequence'" rel="tag" aria-labelledby="tag-sequence-tooltip-container">sequence</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/24039/simon" class="s-avatar s-avatar__16 s-user-card--avatar" data-user-id="24039"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/56e7993be670c363354b696cff311172?s=32&amp;d=identicon&amp;r=PG" alt="Simon's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/24039/simon" class="flex--item">Simon</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 77,709" dir="ltr">77.7k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2009-02-03 22:31:02Z" class="relativetime">Feb 3, 2009 at 22:31</span></time> </div> </div> </div> </div> <div id="question-summary-176918" class="s-post-summary js-post-summary" data-post-id="176918" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 4253"> <span class="s-post-summary--stats-item-number">4253</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">44</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="5834281 views"> <span class="s-post-summary--stats-item-number">5.8m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/176918/finding-the-index-of-an-item-in-a-list" class="s-link">Finding the index of an item in a list</a> </h3> <div class="s-post-summary--content-excerpt"> Given a list [&quot;foo&quot;, &quot;bar&quot;, &quot;baz&quot;] and an item in the list &quot;bar&quot;, how do I get its index 1? </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-list t-indexing"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/list" class="post-tag flex--item mt0 js-tagname-list" title="show questions tagged 'list'" aria-label="show questions tagged 'list'" rel="tag" aria-labelledby="tag-list-tooltip-container">list</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/indexing" class="post-tag flex--item mt0 js-tagname-indexing" title="show questions tagged 'indexing'" aria-label="show questions tagged 'indexing'" rel="tag" aria-labelledby="tag-indexing-tooltip-container">indexing</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/25680/eugene-m" class="s-avatar s-avatar__16 s-user-card--avatar js-user-hover-target" data-user-id="25680"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/69d55a08bdc1f4440ff16d8d13427207?s=32&amp;d=identicon&amp;r=PG" alt="Eugene M's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/25680/eugene-m" class="flex--item">Eugene M</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 46,847" dir="ltr">46.8k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2008-10-07 01:39:38Z" class="relativetime">Oct 7, 2008 at 1:39</span></time> </div> </div> </div> </div> <div id="question-summary-3294889" class="s-post-summary js-post-summary" data-post-id="3294889" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 4106"> <span class="s-post-summary--stats-item-number">4106</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">15</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="5444970 views"> <span class="s-post-summary--stats-item-number">5.4m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/3294889/iterating-over-dictionaries-using-for-loops" class="s-link">Iterating over dictionaries using &#39;for&#39; loops</a> </h3> <div class="s-post-summary--content-excerpt"> d = {'x': 1, 'y': 2, 'z': 3} for key in d: print(key, 'corresponds to', d[key]) How does Python recognize that it needs only to read the key from the dictionary? Is key a special keyword, or is ... </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-dictionary"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/dictionary" class="post-tag flex--item mt0 js-tagname-dictionary" title="show questions tagged 'dictionary'" aria-label="show questions tagged 'dictionary'" rel="tag" aria-labelledby="tag-dictionary-tooltip-container">dictionary</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/1212392/topchef" class="s-avatar s-avatar__16 s-user-card--avatar" data-user-id="1212392"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/2d2462f1533adf1f46730674902713df?s=32&amp;d=identicon&amp;r=PG" alt="TopChef's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/1212392/topchef" class="flex--item">TopChef</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 42,737" dir="ltr">42.7k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2010-07-20 22:27:42Z" class="relativetime">Jul 20, 2010 at 22:27</span></time> </div> </div> </div> </div> <div id="question-summary-423379" class="s-post-summary js-post-summary" data-post-id="423379" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 3834"> <span class="s-post-summary--stats-item-number">3834</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">25</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="3902991 views"> <span class="s-post-summary--stats-item-number">3.9m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/423379/using-global-variables-in-a-function" class="s-link">Using global variables in a function</a> </h3> <div class="s-post-summary--content-excerpt"> How do I create or use a global variable inside a function? How do I use a global variable that was defined in one function inside other functions? Failing to use the global keyword where appropriate ... </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-global-variables t-scope"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/global-variables" class="post-tag flex--item mt0 js-tagname-global-variables" title="show questions tagged 'global-variables'" aria-label="show questions tagged 'global-variables'" rel="tag" aria-labelledby="tag-global-variables-tooltip-container">global-variables</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/scope" class="post-tag flex--item mt0 js-tagname-scope" title="show questions tagged 'scope'" aria-label="show questions tagged 'scope'" rel="tag" aria-labelledby="tag-scope-tooltip-container">scope</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/46646/user46646" class="s-avatar s-avatar__16 s-user-card--avatar" data-user-id="46646"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/a1e278de9bdbf3ecd96d0d786fa97392?s=32&amp;d=identicon&amp;r=PG" alt="user46646's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/46646/user46646" class="flex--item">user46646</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 150,663" dir="ltr">151k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2009-01-08 05:45:02Z" class="relativetime">Jan 8, 2009 at 5:45</span></time> </div> </div> </div> </div> <div id="question-summary-16476924" class="s-post-summary js-post-summary" data-post-id="16476924" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 3796"> <span class="s-post-summary--stats-item-number">3796</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">32</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="6304296 views"> <span class="s-post-summary--stats-item-number">6.3m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/16476924/how-to-iterate-over-rows-in-a-dataframe-in-pandas" class="s-link">How to iterate over rows in a DataFrame in Pandas</a> </h3> <div class="s-post-summary--content-excerpt"> I have a pandas dataframe, df: c1 c2 0 10 100 1 11 110 2 12 120 How do I iterate over the rows of this dataframe? For every row, I want to be able to access its elements (values in cells) ... </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-pandas t-dataframe"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/pandas" class="post-tag flex--item mt0 js-tagname-pandas" title="show questions tagged 'pandas'" aria-label="show questions tagged 'pandas'" rel="tag" aria-labelledby="tag-pandas-tooltip-container">pandas</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/dataframe" class="post-tag flex--item mt0 js-tagname-dataframe" title="show questions tagged 'dataframe'" aria-label="show questions tagged 'dataframe'" rel="tag" aria-labelledby="tag-dataframe-tooltip-container">dataframe</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/245549/roman" class="s-avatar s-avatar__16 s-user-card--avatar" data-user-id="245549"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/eec7e09c7d0731a44e91b403dd0bc347?s=32&amp;d=identicon&amp;r=PG" alt="Roman's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/245549/roman" class="flex--item">Roman</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 120,989" dir="ltr">121k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2013-05-10 07:04:49Z" class="relativetime">May 10, 2013 at 7:04</span></time> </div> </div> </div> </div> <div id="question-summary-415511" class="s-post-summary js-post-summary" data-post-id="415511" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 3703"> <span class="s-post-summary--stats-item-number">3703</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">54</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="4068704 views"> <span class="s-post-summary--stats-item-number">4.1m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/415511/how-do-i-get-the-current-time" class="s-link">How do I get the current time?</a> </h3> <div class="s-post-summary--content-excerpt"> How do I get the current time? </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-datetime t-time"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/datetime" class="post-tag flex--item mt0 js-tagname-datetime" title="show questions tagged 'datetime'" aria-label="show questions tagged 'datetime'" rel="tag" aria-labelledby="tag-datetime-tooltip-container">datetime</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/time" class="post-tag flex--item mt0 js-tagname-time" title="show questions tagged 'time'" aria-label="show questions tagged 'time'" rel="tag" aria-labelledby="tag-time-tooltip-container">time</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/46646/user46646" class="s-avatar s-avatar__16 s-user-card--avatar" data-user-id="46646"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/a1e278de9bdbf3ecd96d0d786fa97392?s=32&amp;d=identicon&amp;r=PG" alt="user46646's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/46646/user46646" class="flex--item">user46646</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 150,663" dir="ltr">151k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2009-01-06 04:54:23Z" class="relativetime">Jan 6, 2009 at 4:54</span></time> </div> </div> </div> </div> <div id="question-summary-6470428" class="s-post-summary js-post-summary" data-post-id="6470428" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 3676"> <span class="s-post-summary--stats-item-number">3676</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">6</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="1341106 views"> <span class="s-post-summary--stats-item-number">1.3m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/6470428/catch-multiple-exceptions-in-one-line-except-block" class="s-link">Catch multiple exceptions in one line (except block)</a> </h3> <div class="s-post-summary--content-excerpt"> I know that I can do: try: # do something that may fail except: # do this if ANYTHING goes wrong I can also do this: try: # do something that may fail except IDontLikeYouException: #... </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-exception"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/exception" class="post-tag flex--item mt0 js-tagname-exception" title="show questions tagged 'exception'" aria-label="show questions tagged 'exception'" rel="tag" aria-labelledby="tag-exception-tooltip-container">exception</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/198633/inspectorg4dget" class="s-avatar s-avatar__16 s-user-card--avatar js-user-hover-target" data-user-id="198633"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/5b9c04999233026354268c2ee4237e04?s=32&amp;d=identicon&amp;r=PG" alt="inspectorG4dget's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/198633/inspectorg4dget" class="flex--item">inspectorG4dget</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 108,542" dir="ltr">109k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2011-06-24 15:55:08Z" class="relativetime">Jun 24, 2011 at 15:55</span></time> </div> </div> </div> </div> <div id="question-summary-3437059" class="s-post-summary js-post-summary" data-post-id="3437059" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 3588"> <span class="s-post-summary--stats-item-number">3588</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">10</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="6317784 views"> <span class="s-post-summary--stats-item-number">6.3m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/3437059/does-python-have-a-string-contains-substring-method" class="s-link">Does Python have a string &#39;contains&#39; substring method?</a> </h3> <div class="s-post-summary--content-excerpt"> I'm looking for a string.contains or string.indexof method in Python. I want to do: if not somestring.contains("blah"): continue </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-string t-substring t-contains"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/string" class="post-tag flex--item mt0 js-tagname-string" title="show questions tagged 'string'" aria-label="show questions tagged 'string'" rel="tag" aria-labelledby="tag-string-tooltip-container">string</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/substring" class="post-tag flex--item mt0 js-tagname-substring" title="show questions tagged 'substring'" aria-label="show questions tagged 'substring'" rel="tag" aria-labelledby="tag-substring-tooltip-container">substring</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/contains" class="post-tag flex--item mt0 js-tagname-contains" title="show questions tagged 'contains'" aria-label="show questions tagged 'contains'" rel="tag" aria-labelledby="tag-contains-tooltip-container">contains</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/39677/blankman" class="s-avatar s-avatar__16 s-user-card--avatar js-user-hover-target" data-user-id="39677"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/77aa7bc1ace6e4b0b49a2102e4fa4059?s=32&amp;d=identicon&amp;r=PG" alt="Blankman's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/39677/blankman" class="flex--item">Blankman</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 256,086" dir="ltr">256k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2010-08-09 02:52:50Z" class="relativetime">Aug 9, 2010 at 2:52</span></time> </div> </div> </div> </div> <div id="question-summary-606191" class="s-post-summary js-post-summary" data-post-id="606191" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 3587"> <span class="s-post-summary--stats-item-number">3587</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">22</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="4628362 views"> <span class="s-post-summary--stats-item-number">4.6m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/606191/convert-bytes-to-a-string" class="s-link">Convert bytes to a string</a> </h3> <div class="s-post-summary--content-excerpt"> I captured the standard output of an external program into a bytes object: &gt;&gt;&gt; from subprocess import * &gt;&gt;&gt; command_stdout = Popen(['ls', '-l'], stdout=PIPE).communicate()[0] &gt;&gt;... </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-string t-python-3ûx"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/string" class="post-tag flex--item mt0 js-tagname-string" title="show questions tagged 'string'" aria-label="show questions tagged 'string'" rel="tag" aria-labelledby="tag-string-tooltip-container">string</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python-3.x" class="post-tag flex--item mt0 js-tagname-python-3ûx" title="show questions tagged 'python-3.x'" aria-label="show questions tagged 'python-3.x'" rel="tag" aria-labelledby="tag-python-3.x-tooltip-container">python-3.x</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/2239/tomas-sedovic" class="s-avatar s-avatar__16 s-user-card--avatar js-user-hover-target" data-user-id="2239"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/57ea101e48765b806d036d536abece6f?s=32&amp;d=identicon&amp;r=PG" alt="Tomas Sedovic's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/2239/tomas-sedovic" class="flex--item">Tomas Sedovic</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 41,687" dir="ltr">41.7k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2009-03-03 12:23:01Z" class="relativetime">Mar 3, 2009 at 12:23</span></time> </div> </div> </div> </div> <div id="question-summary-1436703" class="s-post-summary js-post-summary" data-post-id="1436703" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 3578"> <span class="s-post-summary--stats-item-number">3578</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">28</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="925980 views"> <span class="s-post-summary--stats-item-number">926k</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/1436703/what-is-the-difference-between-str-and-repr" class="s-link">What is the difference between __str__ and __repr__?</a> </h3> <div class="s-post-summary--content-excerpt"> What is the difference between __str__ and __repr__ in Python? </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-magic-methods t-repr"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/magic-methods" class="post-tag flex--item mt0 js-tagname-magic-methods" title="show questions tagged 'magic-methods'" aria-label="show questions tagged 'magic-methods'" rel="tag" aria-labelledby="tag-magic-methods-tooltip-container">magic-methods</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/repr" class="post-tag flex--item mt0 js-tagname-repr" title="show questions tagged 'repr'" aria-label="show questions tagged 'repr'" rel="tag" aria-labelledby="tag-repr-tooltip-container">repr</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/165495/casebash" class="s-avatar s-avatar__16 s-user-card--avatar js-user-hover-target" data-user-id="165495"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://graph.facebook.com/219001761/picture?type=large" alt="Casebash's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/165495/casebash" class="flex--item">Casebash</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 112,545" dir="ltr">113k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2009-09-17 04:27:45Z" class="relativetime">Sep 17, 2009 at 4:27</span></time> </div> </div> </div> </div> <div id="question-summary-123198" class="s-post-summary js-post-summary" data-post-id="123198" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 3568"> <span class="s-post-summary--stats-item-number">3568</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">25</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="3217058 views"> <span class="s-post-summary--stats-item-number">3.2m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/123198/how-to-copy-files" class="s-link">How to copy files</a> </h3> <div class="s-post-summary--content-excerpt"> How do I copy a file in Python? </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-file t-copy t-filesystems t-file-copying"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/file" class="post-tag flex--item mt0 js-tagname-file" title="show questions tagged 'file'" aria-label="show questions tagged 'file'" rel="tag" aria-labelledby="tag-file-tooltip-container">file</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/copy" class="post-tag flex--item mt0 js-tagname-copy" title="show questions tagged 'copy'" aria-label="show questions tagged 'copy'" rel="tag" aria-labelledby="tag-copy-tooltip-container">copy</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/filesystems" class="post-tag flex--item mt0 js-tagname-filesystems" title="show questions tagged 'filesystems'" aria-label="show questions tagged 'filesystems'" rel="tag" aria-labelledby="tag-filesystems-tooltip-container">filesystems</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/file-copying" class="post-tag flex--item mt0 js-tagname-file-copying" title="show questions tagged 'file-copying'" aria-label="show questions tagged 'file-copying'" rel="tag" aria-labelledby="tag-file-copying-tooltip-container">file-copying</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/17693/matt" class="s-avatar s-avatar__16 s-user-card--avatar js-user-hover-target" data-user-id="17693"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://i.stack.imgur.com/JgeMc.png?s=32&amp;g=1" alt="Matt's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/17693/matt" class="flex--item">Matt</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 82,511" dir="ltr">82.5k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2008-09-23 19:23:48Z" class="relativetime">Sep 23, 2008 at 19:23</span></time> </div> </div> </div> </div> <div id="question-summary-448271" class="s-post-summary js-post-summary" data-post-id="448271" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 3493"> <span class="s-post-summary--stats-item-number">3493</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">14</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="2116649 views"> <span class="s-post-summary--stats-item-number">2.1m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/448271/what-is-init-py-for" class="s-link">What is __init__.py for?</a> </h3> <div class="s-post-summary--content-excerpt"> What is __init__.py for in a Python source directory? </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-module t-package t-python-packaging"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/module" class="post-tag flex--item mt0 js-tagname-module" title="show questions tagged 'module'" aria-label="show questions tagged 'module'" rel="tag" aria-labelledby="tag-module-tooltip-container">module</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/package" class="post-tag flex--item mt0 js-tagname-package" title="show questions tagged 'package'" aria-label="show questions tagged 'package'" rel="tag" aria-labelledby="tag-package-tooltip-container">package</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python-packaging" class="post-tag flex--item mt0 js-tagname-python-packaging" title="show questions tagged 'python-packaging'" aria-label="show questions tagged 'python-packaging'" rel="tag" aria-labelledby="tag-python-packaging-tooltip-container">python-packaging</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/42974/mat" class="s-avatar s-avatar__16 s-user-card--avatar" data-user-id="42974"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/9111c5a87d559757e4b10ea2a963e6a3?s=32&amp;d=identicon&amp;r=PG" alt="Mat's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/42974/mat" class="flex--item">Mat</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 80,142" dir="ltr">80.1k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2009-01-15 20:09:09Z" class="relativetime">Jan 15, 2009 at 20:09</span></time> </div> </div> </div> </div> <div id="question-summary-3207219" class="s-post-summary js-post-summary" data-post-id="3207219" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 3467"> <span class="s-post-summary--stats-item-number">3467</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers " title="21 answers"> <span class="s-post-summary--stats-item-number">21</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="7526162 views"> <span class="s-post-summary--stats-item-number">7.5m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/3207219/how-do-i-list-all-files-of-a-directory" class="s-link">How do I list all files of a directory?</a> </h3> <div class="s-post-summary--content-excerpt"> How can I list all files of a directory in Python and add them to a list? </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-directory"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/directory" class="post-tag flex--item mt0 js-tagname-directory" title="show questions tagged 'directory'" aria-label="show questions tagged 'directory'" rel="tag" aria-labelledby="tag-directory-tooltip-container">directory</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/385652/duhhunjonn" class="s-avatar s-avatar__16 s-user-card--avatar" data-user-id="385652"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/11e64aea4e206ff5498ad34adda044b4?s=32&amp;d=identicon&amp;r=PG" alt="duhhunjonn's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/385652/duhhunjonn" class="flex--item">duhhunjonn</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 44,525" dir="ltr">44.5k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2010-07-08 19:31:22Z" class="relativetime">Jul 8, 2010 at 19:31</span></time> </div> </div> </div> </div> <div id="question-summary-1024847" class="s-post-summary js-post-summary" data-post-id="1024847" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 3433"> <span class="s-post-summary--stats-item-number">3433</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">20</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="5104732 views"> <span class="s-post-summary--stats-item-number">5.1m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/1024847/how-can-i-add-new-keys-to-a-dictionary" class="s-link">How can I add new keys to a dictionary?</a> </h3> <div class="s-post-summary--content-excerpt"> How do I add a key to an existing dictionary? It doesn't have an .add() method. </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-dictionary t-lookup"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/dictionary" class="post-tag flex--item mt0 js-tagname-dictionary" title="show questions tagged 'dictionary'" aria-label="show questions tagged 'dictionary'" rel="tag" aria-labelledby="tag-dictionary-tooltip-container">dictionary</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/lookup" class="post-tag flex--item mt0 js-tagname-lookup" title="show questions tagged 'lookup'" aria-label="show questions tagged 'lookup'" rel="tag" aria-labelledby="tag-lookup-tooltip-container">lookup</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/90777/lfaraone" class="s-avatar s-avatar__16 s-user-card--avatar js-user-hover-target" data-user-id="90777"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/43918f842a892d0deb9ef1d8dcc9fe49?s=32&amp;d=identicon&amp;r=PG" alt="lfaraone's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/90777/lfaraone" class="flex--item">lfaraone</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 49,084" dir="ltr">49.1k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2009-06-21 22:07:39Z" class="relativetime">Jun 21, 2009 at 22:07</span></time> </div> </div> </div> </div> <div id="question-summary-613183" class="s-post-summary js-post-summary" data-post-id="613183" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 3416"> <span class="s-post-summary--stats-item-number">3416</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">34</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="4947976 views"> <span class="s-post-summary--stats-item-number">4.9m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/613183/how-do-i-sort-a-dictionary-by-value" class="s-link">How do I sort a dictionary by value?</a> </h3> <div class="s-post-summary--content-excerpt"> I have a dictionary of values read from two fields in a database: a string field and a numeric field. The string field is unique, so that is the key of the dictionary. I can sort on the keys, but how ... </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-sorting t-dictionary"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/sorting" class="post-tag flex--item mt0 js-tagname-sorting" title="show questions tagged 'sorting'" aria-label="show questions tagged 'sorting'" rel="tag" aria-labelledby="tag-sorting-tooltip-container">sorting</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/dictionary" class="post-tag flex--item mt0 js-tagname-dictionary" title="show questions tagged 'dictionary'" aria-label="show questions tagged 'dictionary'" rel="tag" aria-labelledby="tag-dictionary-tooltip-container">dictionary</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/2786/gern-blanston" class="s-avatar s-avatar__16 s-user-card--avatar js-user-hover-target" data-user-id="2786"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/a82355039ccbe7d12a8ffee222dc225d?s=32&amp;d=identicon&amp;r=PG" alt="Gern Blanston's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/2786/gern-blanston" class="flex--item">Gern Blanston</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 42,354" dir="ltr">42.4k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2009-03-05 00:49:05Z" class="relativetime">Mar 5, 2009 at 0:49</span></time> </div> </div> </div> </div> <div id="question-summary-17071871" class="s-post-summary js-post-summary" data-post-id="17071871" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 3288"> <span class="s-post-summary--stats-item-number">3288</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">16</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="5611604 views"> <span class="s-post-summary--stats-item-number">5.6m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/17071871/how-do-i-select-rows-from-a-dataframe-based-on-column-values" class="s-link">How do I select rows from a DataFrame based on column values?</a> </h3> <div class="s-post-summary--content-excerpt"> How can I select rows from a DataFrame based on values in some column in Pandas? In SQL, I would use: SELECT * FROM table WHERE column_name = some_value </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-pandas t-dataframe"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/pandas" class="post-tag flex--item mt0 js-tagname-pandas" title="show questions tagged 'pandas'" aria-label="show questions tagged 'pandas'" rel="tag" aria-labelledby="tag-pandas-tooltip-container">pandas</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/dataframe" class="post-tag flex--item mt0 js-tagname-dataframe" title="show questions tagged 'dataframe'" aria-label="show questions tagged 'dataframe'" rel="tag" aria-labelledby="tag-dataframe-tooltip-container">dataframe</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/458429/szli" class="s-avatar s-avatar__16 s-user-card--avatar" data-user-id="458429"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/00331dfb525be62f49a12e6baa934198?s=32&amp;d=identicon&amp;r=PG" alt="szli's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/458429/szli" class="flex--item">szli</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 35,793" dir="ltr">35.8k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2013-06-12 17:42:05Z" class="relativetime">Jun 12, 2013 at 17:42</span></time> </div> </div> </div> </div> <div id="question-summary-1132941" class="s-post-summary js-post-summary" data-post-id="1132941" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 3288"> <span class="s-post-summary--stats-item-number">3288</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">33</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="242789 views"> <span class="s-post-summary--stats-item-number">243k</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/1132941/least-astonishment-and-the-mutable-default-argument" class="s-link">&quot;Least Astonishment&quot; and the Mutable Default Argument</a> </h3> <div class="s-post-summary--content-excerpt"> Anyone tinkering with Python long enough has been bitten (or torn to pieces) by the following issue: def foo(a=[]): a.append(5) return a Python novices would expect this function called with ... </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-language-design t-default-parameters t-least-astonishment"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/language-design" class="post-tag flex--item mt0 js-tagname-language-design" title="show questions tagged 'language-design'" aria-label="show questions tagged 'language-design'" rel="tag" aria-labelledby="tag-language-design-tooltip-container">language-design</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/default-parameters" class="post-tag flex--item mt0 js-tagname-default-parameters" title="show questions tagged 'default-parameters'" aria-label="show questions tagged 'default-parameters'" rel="tag" aria-labelledby="tag-default-parameters-tooltip-container">default-parameters</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/least-astonishment" class="post-tag flex--item mt0 js-tagname-least-astonishment" title="show questions tagged 'least-astonishment'" aria-label="show questions tagged 'least-astonishment'" rel="tag" aria-labelledby="tag-least-astonishment-tooltip-container">least-astonishment</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/78374/stefano-borini" class="s-avatar s-avatar__16 s-user-card--avatar" data-user-id="78374"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/f13cb1b1bd8b16bf6dc6eda558e162a0?s=32&amp;d=identicon&amp;r=PG" alt="Stefano Borini's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/78374/stefano-borini" class="flex--item">Stefano Borini</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 136,370" dir="ltr">136k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2009-07-15 18:00:37Z" class="relativetime">Jul 15, 2009 at 18:00</span></time> </div> </div> </div> </div> <div id="question-summary-1720421" class="s-post-summary js-post-summary" data-post-id="1720421" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 3244"> <span class="s-post-summary--stats-item-number">3244</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">31</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="4075162 views"> <span class="s-post-summary--stats-item-number">4.1m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/1720421/how-do-i-concatenate-two-lists-in-python" class="s-link">How do I concatenate two lists in Python?</a> </h3> <div class="s-post-summary--content-excerpt"> How do I concatenate two lists in Python? Example: listone = [1, 2, 3] listtwo = [4, 5, 6] Expected outcome: &gt;&gt;&gt; joinedlist [1, 2, 3, 4, 5, 6] </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-list t-concatenation"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/list" class="post-tag flex--item mt0 js-tagname-list" title="show questions tagged 'list'" aria-label="show questions tagged 'list'" rel="tag" aria-labelledby="tag-list-tooltip-container">list</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/concatenation" class="post-tag flex--item mt0 js-tagname-concatenation" title="show questions tagged 'concatenation'" aria-label="show questions tagged 'concatenation'" rel="tag" aria-labelledby="tag-concatenation-tooltip-container">concatenation</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/206504/y2k" class="s-avatar s-avatar__16 s-user-card--avatar" data-user-id="206504"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/b6a63b3808f15037e9044a43f0620ffd?s=32&amp;d=identicon&amp;r=PG" alt="y2k's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/206504/y2k" class="flex--item">y2k</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 65,048" dir="ltr">65k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2009-11-12 07:04:09Z" class="relativetime">Nov 12, 2009 at 7:04</span></time> </div> </div> </div> </div> <div id="question-summary-36901" class="s-post-summary js-post-summary" data-post-id="36901" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 3239"> <span class="s-post-summary--stats-item-number">3239</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">25</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="1222926 views"> <span class="s-post-summary--stats-item-number">1.2m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/36901/what-does-double-star-asterisk-and-star-asterisk-do-for-parameters" class="s-link">What does ** (double star/asterisk) and * (star/asterisk) do for parameters?</a> </h3> <div class="s-post-summary--content-excerpt"> What do *args and **kwargs mean in these function definitions? def foo(x, y, *args): pass def bar(x, y, **kwargs): pass See What do ** (double star/asterisk) and * (star/asterisk) mean in a ... </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-syntax t-parameter-passing t-variadic-functions t-argument-unpacking"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/syntax" class="post-tag flex--item mt0 js-tagname-syntax" title="show questions tagged 'syntax'" aria-label="show questions tagged 'syntax'" rel="tag" aria-labelledby="tag-syntax-tooltip-container">syntax</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/parameter-passing" class="post-tag flex--item mt0 js-tagname-parameter-passing" title="show questions tagged 'parameter-passing'" aria-label="show questions tagged 'parameter-passing'" rel="tag" aria-labelledby="tag-parameter-passing-tooltip-container">parameter-passing</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/variadic-functions" class="post-tag flex--item mt0 js-tagname-variadic-functions" title="show questions tagged 'variadic-functions'" aria-label="show questions tagged 'variadic-functions'" rel="tag" aria-labelledby="tag-variadic-functions-tooltip-container">variadic-functions</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/argument-unpacking" class="post-tag flex--item mt0 js-tagname-argument-unpacking" title="show questions tagged 'argument-unpacking'" aria-label="show questions tagged 'argument-unpacking'" rel="tag" aria-labelledby="tag-argument-unpacking-tooltip-container">argument-unpacking</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/2572/todd" class="s-avatar s-avatar__16 s-user-card--avatar" data-user-id="2572"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/133b9402dcc48504a13732d459b7eaa8?s=32&amp;d=identicon&amp;r=PG" alt="Todd's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/2572/todd" class="flex--item">Todd</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 33,720" dir="ltr">33.7k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2008-08-31 15:04:35Z" class="relativetime">Aug 31, 2008 at 15:04</span></time> </div> </div> </div> </div> <div id="question-summary-53513" class="s-post-summary js-post-summary" data-post-id="53513" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 3229"> <span class="s-post-summary--stats-item-number">3229</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">27</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="4519384 views"> <span class="s-post-summary--stats-item-number">4.5m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/53513/how-do-i-check-if-a-list-is-empty" class="s-link">How do I check if a list is empty?</a> </h3> <div class="s-post-summary--content-excerpt"> For example, if passed the following: a = [] How do I check to see if a is empty? </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-list"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/list" class="post-tag flex--item mt0 js-tagname-list" title="show questions tagged 'list'" aria-label="show questions tagged 'list'" rel="tag" aria-labelledby="tag-list-tooltip-container">list</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/4872/ray" class="s-avatar s-avatar__16 s-user-card--avatar js-user-hover-target" data-user-id="4872"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/2da21199d56ce93c5092f1c386d5a577?s=32&amp;d=identicon&amp;r=PG" alt="Ray's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/4872/ray" class="flex--item">Ray</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 184,476" dir="ltr">184k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2008-09-10 06:20:11Z" class="relativetime">Sep 10, 2008 at 6:20</span></time> </div> </div> </div> </div> <div id="question-summary-986006" class="s-post-summary js-post-summary" data-post-id="986006" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 3210"> <span class="s-post-summary--stats-item-number">3210</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">39</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="1905851 views"> <span class="s-post-summary--stats-item-number">1.9m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/986006/how-do-i-pass-a-variable-by-reference" class="s-link">How do I pass a variable by reference?</a> </h3> <div class="s-post-summary--content-excerpt"> Are parameters passed by reference or by value? How do I pass by reference so that the code below outputs 'Changed' instead of 'Original'? class PassByReference: def __init__(self): self.... </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-reference t-parameter-passing t-pass-by-reference"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/reference" class="post-tag flex--item mt0 js-tagname-reference" title="show questions tagged 'reference'" aria-label="show questions tagged 'reference'" rel="tag" aria-labelledby="tag-reference-tooltip-container">reference</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/parameter-passing" class="post-tag flex--item mt0 js-tagname-parameter-passing" title="show questions tagged 'parameter-passing'" aria-label="show questions tagged 'parameter-passing'" rel="tag" aria-labelledby="tag-parameter-passing-tooltip-container">parameter-passing</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/pass-by-reference" class="post-tag flex--item mt0 js-tagname-pass-by-reference" title="show questions tagged 'pass-by-reference'" aria-label="show questions tagged 'pass-by-reference'" rel="tag" aria-labelledby="tag-pass-by-reference-tooltip-container">pass-by-reference</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/259/david-sykes" class="s-avatar s-avatar__16 s-user-card--avatar" data-user-id="259"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/0c95a3798d9a008b6c29605b8f15b47a?s=32&amp;d=identicon&amp;r=PG" alt="David Sykes's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/259/david-sykes" class="flex--item">David Sykes</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 47,734" dir="ltr">47.7k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2009-06-12 10:23:51Z" class="relativetime">Jun 12, 2009 at 10:23</span></time> </div> </div> </div> </div> <div id="question-summary-2612802" class="s-post-summary js-post-summary" data-post-id="2612802" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 3198"> <span class="s-post-summary--stats-item-number">3198</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">24</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="2092590 views"> <span class="s-post-summary--stats-item-number">2.1m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/2612802/how-do-i-clone-a-list-so-that-it-doesnt-change-unexpectedly-after-assignment" class="s-link">How do I clone a list so that it doesn&#39;t change unexpectedly after assignment?</a> </h3> <div class="s-post-summary--content-excerpt"> While using new_list = my_list, any modifications to new_list changes my_list every time. Why is this, and how can I clone or copy the list to prevent it? </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-list t-reference t-clone t-pass-by-value"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/list" class="post-tag flex--item mt0 js-tagname-list" title="show questions tagged 'list'" aria-label="show questions tagged 'list'" rel="tag" aria-labelledby="tag-list-tooltip-container">list</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/reference" class="post-tag flex--item mt0 js-tagname-reference" title="show questions tagged 'reference'" aria-label="show questions tagged 'reference'" rel="tag" aria-labelledby="tag-reference-tooltip-container">reference</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/clone" class="post-tag flex--item mt0 js-tagname-clone" title="show questions tagged 'clone'" aria-label="show questions tagged 'clone'" rel="tag" aria-labelledby="tag-clone-tooltip-container">clone</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/pass-by-value" class="post-tag flex--item mt0 js-tagname-pass-by-value" title="show questions tagged 'pass-by-value'" aria-label="show questions tagged 'pass-by-value'" rel="tag" aria-labelledby="tag-pass-by-value-tooltip-container">pass-by-value</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/187730/af" class="s-avatar s-avatar__16 s-user-card--avatar js-user-hover-target" data-user-id="187730"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/779f1fe080fea457f5ab867d34572363?s=32&amp;d=identicon&amp;r=PG" alt="aF.'s user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/187730/af" class="flex--item">aF.</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 64,172" dir="ltr">64.2k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2010-04-10 08:49:46Z" class="relativetime">Apr 10, 2010 at 8:49</span></time> </div> </div> </div> </div> <div id="question-summary-6996603" class="s-post-summary js-post-summary" data-post-id="6996603" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 3174"> <span class="s-post-summary--stats-item-number">3174</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">15</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="3106834 views"> <span class="s-post-summary--stats-item-number">3.1m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/6996603/how-can-i-delete-a-file-or-folder-in-python" class="s-link">How can I delete a file or folder in Python?</a> </h3> <div class="s-post-summary--content-excerpt"> How can I delete a file or folder? </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-file-io t-directory t-delete-file"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/file-io" class="post-tag flex--item mt0 js-tagname-file-io" title="show questions tagged 'file-io'" aria-label="show questions tagged 'file-io'" rel="tag" aria-labelledby="tag-file-io-tooltip-container">file-io</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/directory" class="post-tag flex--item mt0 js-tagname-directory" title="show questions tagged 'directory'" aria-label="show questions tagged 'directory'" rel="tag" aria-labelledby="tag-directory-tooltip-container">directory</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/delete-file" class="post-tag flex--item mt0 js-tagname-delete-file" title="show questions tagged 'delete-file'" aria-label="show questions tagged 'delete-file'" rel="tag" aria-labelledby="tag-delete-file-tooltip-container">delete-file</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/854002/zygimantas" class="s-avatar s-avatar__16 s-user-card--avatar js-user-hover-target" data-user-id="854002"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/3c39cfc2108eb01085e1c5dd1cced80f?s=32&amp;d=identicon&amp;r=PG" alt="Zygimantas's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/854002/zygimantas" class="flex--item">Zygimantas</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 32,065" dir="ltr">32.1k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2011-08-09 13:05:42Z" class="relativetime">Aug 9, 2011 at 13:05</span></time> </div> </div> </div> </div> <div id="question-summary-510348" class="s-post-summary js-post-summary" data-post-id="510348" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 3148"> <span class="s-post-summary--stats-item-number">3148</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers " title="13 answers"> <span class="s-post-summary--stats-item-number">13</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="3608674 views"> <span class="s-post-summary--stats-item-number">3.6m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/510348/how-do-i-make-a-time-delay" class="s-link">How do I make a time delay? [duplicate]</a> </h3> <div class="s-post-summary--content-excerpt"> How do I put a time delay in a Python script? </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-delay t-sleep t-timedelay"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/delay" class="post-tag flex--item mt0 js-tagname-delay" title="show questions tagged 'delay'" aria-label="show questions tagged 'delay'" rel="tag" aria-labelledby="tag-delay-tooltip-container">delay</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/sleep" class="post-tag flex--item mt0 js-tagname-sleep" title="show questions tagged 'sleep'" aria-label="show questions tagged 'sleep'" rel="tag" aria-labelledby="tag-sleep-tooltip-container">sleep</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/timedelay" class="post-tag flex--item mt0 js-tagname-timedelay" title="show questions tagged 'timedelay'" aria-label="show questions tagged 'timedelay'" rel="tag" aria-labelledby="tag-timedelay-tooltip-container">timedelay</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/46646/user46646" class="s-avatar s-avatar__16 s-user-card--avatar" data-user-id="46646"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/a1e278de9bdbf3ecd96d0d786fa97392?s=32&amp;d=identicon&amp;r=PG" alt="user46646's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/46646/user46646" class="flex--item">user46646</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 150,663" dir="ltr">151k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2009-02-04 07:04:09Z" class="relativetime">Feb 4, 2009 at 7:04</span></time> </div> </div> </div> </div> <div id="question-summary-576169" class="s-post-summary js-post-summary" data-post-id="576169" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 3133"> <span class="s-post-summary--stats-item-number">3133</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">7</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="2448344 views"> <span class="s-post-summary--stats-item-number">2.4m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/576169/understanding-python-super-with-init-methods" class="s-link">Understanding Python super() with __init__() methods [duplicate]</a> </h3> <div class="s-post-summary--content-excerpt"> Why is super() used? Is there a difference between using Base.__init__ and super().__init__? class Base(object): def __init__(self): print &quot;Base created&quot; class ChildA(... </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-class t-oop t-inheritance t-super"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/class" class="post-tag flex--item mt0 js-tagname-class" title="show questions tagged 'class'" aria-label="show questions tagged 'class'" rel="tag" aria-labelledby="tag-class-tooltip-container">class</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/oop" class="post-tag flex--item mt0 js-tagname-oop" title="show questions tagged 'oop'" aria-label="show questions tagged 'oop'" rel="tag" aria-labelledby="tag-oop-tooltip-container">oop</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/inheritance" class="post-tag flex--item mt0 js-tagname-inheritance" title="show questions tagged 'inheritance'" aria-label="show questions tagged 'inheritance'" rel="tag" aria-labelledby="tag-inheritance-tooltip-container">inheritance</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/super" class="post-tag flex--item mt0 js-tagname-super" title="show questions tagged 'super'" aria-label="show questions tagged 'super'" rel="tag" aria-labelledby="tag-super-tooltip-container">super</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/56763/mizipzor" class="s-avatar s-avatar__16 s-user-card--avatar js-user-hover-target" data-user-id="56763"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/9e9bb40f93094055bd09193eb3bccbb8?s=32&amp;d=identicon&amp;r=PG" alt="Mizipzor's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/56763/mizipzor" class="flex--item">Mizipzor</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 50,401" dir="ltr">50.4k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2009-02-23 00:30:08Z" class="relativetime">Feb 23, 2009 at 0:30</span></time> </div> </div> </div> </div> <div id="question-summary-252703" class="s-post-summary js-post-summary" data-post-id="252703" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 3113"> <span class="s-post-summary--stats-item-number">3113</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">20</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="3231219 views"> <span class="s-post-summary--stats-item-number">3.2m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/252703/what-is-the-difference-between-pythons-list-methods-append-and-extend" class="s-link">What is the difference between Python&#39;s list methods append and extend?</a> </h3> <div class="s-post-summary--content-excerpt"> What's the difference between the list methods append() and extend()? </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-list t-data-structures t-append t-extend"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/list" class="post-tag flex--item mt0 js-tagname-list" title="show questions tagged 'list'" aria-label="show questions tagged 'list'" rel="tag" aria-labelledby="tag-list-tooltip-container">list</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/data-structures" class="post-tag flex--item mt0 js-tagname-data-structures" title="show questions tagged 'data-structures'" aria-label="show questions tagged 'data-structures'" rel="tag" aria-labelledby="tag-data-structures-tooltip-container">data-structures</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/append" class="post-tag flex--item mt0 js-tagname-append" title="show questions tagged 'append'" aria-label="show questions tagged 'append'" rel="tag" aria-labelledby="tag-append-tooltip-container">append</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/extend" class="post-tag flex--item mt0 js-tagname-extend" title="show questions tagged 'extend'" aria-label="show questions tagged 'extend'" rel="tag" aria-labelledby="tag-extend-tooltip-container">extend</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/15055/claudiu" class="s-avatar s-avatar__16 s-user-card--avatar js-user-hover-target" data-user-id="15055"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/7f71287b47b7189d11fe6d3fbc7ed2fe?s=32&amp;d=identicon&amp;r=PG" alt="Claudiu's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/15055/claudiu" class="flex--item">Claudiu</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 221,716" dir="ltr">222k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2008-10-31 05:55:36Z" class="relativetime">Oct 31, 2008 at 5:55</span></time> </div> </div> </div> </div> <div id="question-summary-332289" class="s-post-summary js-post-summary" data-post-id="332289" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 3102"> <span class="s-post-summary--stats-item-number">3102</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers " title="14 answers"> <span class="s-post-summary--stats-item-number">14</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="5636629 views"> <span class="s-post-summary--stats-item-number">5.6m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/332289/how-do-i-change-the-size-of-figures-drawn-with-matplotlib" class="s-link">How do I change the size of figures drawn with Matplotlib?</a> </h3> <div class="s-post-summary--content-excerpt"> How do I change the size of figure drawn with Matplotlib? </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-pandas t-matplotlib t-seaborn t-figsize"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/pandas" class="post-tag flex--item mt0 js-tagname-pandas" title="show questions tagged 'pandas'" aria-label="show questions tagged 'pandas'" rel="tag" aria-labelledby="tag-pandas-tooltip-container">pandas</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/matplotlib" class="post-tag flex--item mt0 js-tagname-matplotlib" title="show questions tagged 'matplotlib'" aria-label="show questions tagged 'matplotlib'" rel="tag" aria-labelledby="tag-matplotlib-tooltip-container">matplotlib</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/seaborn" class="post-tag flex--item mt0 js-tagname-seaborn" title="show questions tagged 'seaborn'" aria-label="show questions tagged 'seaborn'" rel="tag" aria-labelledby="tag-seaborn-tooltip-container">seaborn</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/figsize" class="post-tag flex--item mt0 js-tagname-figsize" title="show questions tagged 'figsize'" aria-label="show questions tagged 'figsize'" rel="tag" aria-labelledby="tag-figsize-tooltip-container">figsize</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/40849/tatwright" class="s-avatar s-avatar__16 s-user-card--avatar" data-user-id="40849"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/da1c6e03b2ed78782c80a244a985b2b1?s=32&amp;d=identicon&amp;r=PG" alt="tatwright's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/40849/tatwright" class="flex--item">tatwright</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 36,919" dir="ltr">36.9k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2008-12-01 21:24:44Z" class="relativetime">Dec 1, 2008 at 21:24</span></time> </div> </div> </div> </div> <div id="question-summary-739654" class="s-post-summary js-post-summary" data-post-id="739654" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 3100"> <span class="s-post-summary--stats-item-number">3100</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">20</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="630717 views"> <span class="s-post-summary--stats-item-number">631k</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/739654/how-do-i-make-function-decorators-and-chain-them-together" class="s-link">How do I make function decorators and chain them together?</a> </h3> <div class="s-post-summary--content-excerpt"> How do I make two decorators in Python that would do the following? @make_bold @make_italic def say(): return &quot;Hello&quot; Calling say() should return: &quot;&lt;b&gt;&lt;i&gt;Hello&lt;/i&gt;&amp;... </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-function t-decorator t-python-decorators t-chain"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/function" class="post-tag flex--item mt0 js-tagname-function" title="show questions tagged 'function'" aria-label="show questions tagged 'function'" rel="tag" aria-labelledby="tag-function-tooltip-container">function</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/decorator" class="post-tag flex--item mt0 js-tagname-decorator" title="show questions tagged 'decorator'" aria-label="show questions tagged 'decorator'" rel="tag" aria-labelledby="tag-decorator-tooltip-container">decorator</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python-decorators" class="post-tag flex--item mt0 js-tagname-python-decorators" title="show questions tagged 'python-decorators'" aria-label="show questions tagged 'python-decorators'" rel="tag" aria-labelledby="tag-python-decorators-tooltip-container">python-decorators</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/chain" class="post-tag flex--item mt0 js-tagname-chain" title="show questions tagged 'chain'" aria-label="show questions tagged 'chain'" rel="tag" aria-labelledby="tag-chain-tooltip-container">chain</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/1897/imran" class="s-avatar s-avatar__16 s-user-card--avatar" data-user-id="1897"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/09d9b10ad83581c21328d44e48c77b9d?s=32&amp;d=identicon&amp;r=PG" alt="Imran's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/1897/imran" class="flex--item">Imran</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 85,413" dir="ltr">85.4k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2009-04-11 07:05:31Z" class="relativetime">Apr 11, 2009 at 7:05</span></time> </div> </div> </div> </div> <div id="question-summary-2052390" class="s-post-summary js-post-summary" data-post-id="2052390" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 3062"> <span class="s-post-summary--stats-item-number">3062</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">11</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="2757550 views"> <span class="s-post-summary--stats-item-number">2.8m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/2052390/manually-raising-throwing-an-exception-in-python" class="s-link">Manually raising (throwing) an exception in Python</a> </h3> <div class="s-post-summary--content-excerpt"> How do I raise an exception in Python so that it can later be caught via an except block? </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-exception"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/exception" class="post-tag flex--item mt0 js-tagname-exception" title="show questions tagged 'exception'" aria-label="show questions tagged 'exception'" rel="tag" aria-labelledby="tag-exception-tooltip-container">exception</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/179736/timex" class="s-avatar s-avatar__16 s-user-card--avatar" data-user-id="179736"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/e77327f7ef0c6213525de4dcea19b200?s=32&amp;d=identicon&amp;r=PG" alt="TIMEX's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/179736/timex" class="flex--item">TIMEX</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 252,800" dir="ltr">253k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2010-01-12 21:07:40Z" class="relativetime">Jan 12, 2010 at 21:07</span></time> </div> </div> </div> </div> <div id="question-summary-287871" class="s-post-summary js-post-summary" data-post-id="287871" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 3017"> <span class="s-post-summary--stats-item-number">3017</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers " title="64 answers"> <span class="s-post-summary--stats-item-number">64</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="2198480 views"> <span class="s-post-summary--stats-item-number">2.2m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/287871/how-do-i-print-colored-text-to-the-terminal" class="s-link">How do I print colored text to the terminal?</a> </h3> <div class="s-post-summary--content-excerpt"> How do I output colored text to the terminal in Python? </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-terminal t-output t-ansi-colors"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/terminal" class="post-tag flex--item mt0 js-tagname-terminal" title="show questions tagged 'terminal'" aria-label="show questions tagged 'terminal'" rel="tag" aria-labelledby="tag-terminal-tooltip-container">terminal</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/output" class="post-tag flex--item mt0 js-tagname-output" title="show questions tagged 'output'" aria-label="show questions tagged 'output'" rel="tag" aria-labelledby="tag-output-tooltip-container">output</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/ansi-colors" class="post-tag flex--item mt0 js-tagname-ansi-colors" title="show questions tagged 'ansi-colors'" aria-label="show questions tagged 'ansi-colors'" rel="tag" aria-labelledby="tag-ansi-colors-tooltip-container">ansi-colors</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/35062/abosamoor" class="s-avatar s-avatar__16 s-user-card--avatar" data-user-id="35062"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/a4a5a96e9c857f44d43456579cddc51a?s=32&amp;d=identicon&amp;r=PG" alt="aboSamoor's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/35062/abosamoor" class="flex--item">aboSamoor</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 30,371" dir="ltr">30.4k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2008-11-13 18:58:10Z" class="relativetime">Nov 13, 2008 at 18:58</span></time> </div> </div> </div> </div> <div id="question-summary-4906977" class="s-post-summary js-post-summary" data-post-id="4906977" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 3015"> <span class="s-post-summary--stats-item-number">3015</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">16</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="2687993 views"> <span class="s-post-summary--stats-item-number">2.7m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/4906977/how-can-i-access-environment-variables-in-python" class="s-link">How can I access environment variables in Python?</a> </h3> <div class="s-post-summary--content-excerpt"> How can I get the value of an environment variable in Python? </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-environment-variables"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/environment-variables" class="post-tag flex--item mt0 js-tagname-environment-variables" title="show questions tagged 'environment-variables'" aria-label="show questions tagged 'environment-variables'" rel="tag" aria-labelledby="tag-environment-variables-tooltip-container">environment-variables</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/601738/amit-yadav" class="s-avatar s-avatar__16 s-user-card--avatar js-user-hover-target" data-user-id="601738"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://i.stack.imgur.com/Zpgph.jpg?s=32&amp;g=1" alt="Amit Yadav's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/601738/amit-yadav" class="flex--item">Amit Yadav</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 31,522" dir="ltr">31.5k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2011-02-05 13:03:35Z" class="relativetime">Feb 5, 2011 at 13:03</span></time> </div> </div> </div> </div> <div id="question-summary-312443" class="s-post-summary js-post-summary" data-post-id="312443" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 2994"> <span class="s-post-summary--stats-item-number">2994</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">66</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="1533111 views"> <span class="s-post-summary--stats-item-number">1.5m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/312443/how-do-i-split-a-list-into-equally-sized-chunks" class="s-link">How do I split a list into equally-sized chunks?</a> </h3> <div class="s-post-summary--content-excerpt"> How do I split a list of arbitrary length into equal sized chunks? See How to iterate over a list in chunks if the data result will be used directly for a loop, and does not need to be stored. For ... </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-list t-split t-chunks"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/list" class="post-tag flex--item mt0 js-tagname-list" title="show questions tagged 'list'" aria-label="show questions tagged 'list'" rel="tag" aria-labelledby="tag-list-tooltip-container">list</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/split" class="post-tag flex--item mt0 js-tagname-split" title="show questions tagged 'split'" aria-label="show questions tagged 'split'" rel="tag" aria-labelledby="tag-split-tooltip-container">split</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/chunks" class="post-tag flex--item mt0 js-tagname-chunks" title="show questions tagged 'chunks'" aria-label="show questions tagged 'chunks'" rel="tag" aria-labelledby="tag-chunks-tooltip-container">chunks</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/112415/jespern" class="s-avatar s-avatar__16 s-user-card--avatar" data-user-id="112415"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/b658715b9635ef057daf2a22d4a8f36e?s=32&amp;d=identicon&amp;r=PG" alt="jespern's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/112415/jespern" class="flex--item">jespern</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 31,716" dir="ltr">31.7k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2008-11-23 12:15:52Z" class="relativetime">Nov 23, 2008 at 12:15</span></time> </div> </div> </div> </div> <div id="question-summary-466345" class="s-post-summary js-post-summary" data-post-id="466345" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 2899"> <span class="s-post-summary--stats-item-number">2899</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">26</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="4476308 views"> <span class="s-post-summary--stats-item-number">4.5m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/466345/convert-string-jun-1-2005-133pm-into-datetime" class="s-link">Convert string &quot;Jun 1 2005 1:33PM&quot; into datetime</a> </h3> <div class="s-post-summary--content-excerpt"> How do I convert the following string to a datetime object? &quot;Jun 1 2005 1:33PM&quot; </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-datetime"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/datetime" class="post-tag flex--item mt0 js-tagname-datetime" title="show questions tagged 'datetime'" aria-label="show questions tagged 'datetime'" rel="tag" aria-labelledby="tag-datetime-tooltip-container">datetime</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/12870/oli" class="s-avatar s-avatar__16 s-user-card--avatar js-user-hover-target" data-user-id="12870"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/f0af40756420859b5b63cbceb6d30505?s=32&amp;d=identicon&amp;r=PG" alt="Oli's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/12870/oli" class="flex--item">Oli</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 233,492" dir="ltr">233k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2009-01-21 18:00:29Z" class="relativetime">Jan 21, 2009 at 18:00</span></time> </div> </div> </div> </div> <div id="question-summary-30081275" class="s-post-summary js-post-summary" data-post-id="30081275" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 2892"> <span class="s-post-summary--stats-item-number">2892</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">12</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="341334 views"> <span class="s-post-summary--stats-item-number">341k</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/30081275/why-is-1000000000000000-in-range1000000000000001-so-fast-in-python-3" class="s-link">Why is &quot;1000000000000000 in range(1000000000000001)&quot; so fast in Python 3?</a> </h3> <div class="s-post-summary--content-excerpt"> It is my understanding that the range() function, which is actually an object type in Python 3, generates its contents on the fly, similar to a generator. This being the case, I would have expected ... </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-performance t-python-3ûx t-range t-python-internals"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/performance" class="post-tag flex--item mt0 js-tagname-performance" title="show questions tagged 'performance'" aria-label="show questions tagged 'performance'" rel="tag" aria-labelledby="tag-performance-tooltip-container">performance</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python-3.x" class="post-tag flex--item mt0 js-tagname-python-3ûx" title="show questions tagged 'python-3.x'" aria-label="show questions tagged 'python-3.x'" rel="tag" aria-labelledby="tag-python-3.x-tooltip-container">python-3.x</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/range" class="post-tag flex--item mt0 js-tagname-range" title="show questions tagged 'range'" aria-label="show questions tagged 'range'" rel="tag" aria-labelledby="tag-range-tooltip-container">range</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python-internals" class="post-tag flex--item mt0 js-tagname-python-internals" title="show questions tagged 'python-internals'" aria-label="show questions tagged 'python-internals'" rel="tag" aria-labelledby="tag-python-internals-tooltip-container">python-internals</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/2437514/rick" class="s-avatar s-avatar__16 s-user-card--avatar js-user-hover-target" data-user-id="2437514"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://i.stack.imgur.com/8QN0K.jpg?s=32&amp;g=1" alt="Rick's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/2437514/rick" class="flex--item">Rick</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 41,727" dir="ltr">41.7k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2015-05-06 15:32:43Z" class="relativetime">May 6, 2015 at 15:32</span></time> </div> </div> </div> </div> <div id="question-summary-5137497" class="s-post-summary js-post-summary" data-post-id="5137497" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 2873"> <span class="s-post-summary--stats-item-number">2873</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">13</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="4398086 views"> <span class="s-post-summary--stats-item-number">4.4m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/5137497/find-the-current-directory-and-files-directory" class="s-link">Find the current directory and file&#39;s directory [duplicate]</a> </h3> <div class="s-post-summary--content-excerpt"> How do I determine: the current directory (where I was in the shell when I ran the Python script), and where the Python file I am executing is? </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-directory"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/directory" class="post-tag flex--item mt0 js-tagname-directory" title="show questions tagged 'directory'" aria-label="show questions tagged 'directory'" rel="tag" aria-labelledby="tag-directory-tooltip-container">directory</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/374797/john-howard" class="s-avatar s-avatar__16 s-user-card--avatar" data-user-id="374797"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/7a7c59685abf968ca5ef37f79668ec93?s=32&amp;d=identicon&amp;r=PG&amp;f=1" alt="John Howard's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/374797/john-howard" class="flex--item">John Howard</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 59,501" dir="ltr">59.5k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2011-02-28 01:51:21Z" class="relativetime">Feb 28, 2011 at 1:51</span></time> </div> </div> </div> </div> <div id="question-summary-11346283" class="s-post-summary js-post-summary" data-post-id="11346283" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 2792"> <span class="s-post-summary--stats-item-number">2792</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">35</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="5596524 views"> <span class="s-post-summary--stats-item-number">5.6m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/11346283/renaming-column-names-in-pandas" class="s-link">Renaming column names in Pandas</a> </h3> <div class="s-post-summary--content-excerpt"> I want to change the column labels of a Pandas DataFrame from ['$a', '$b', '$c', '$d', '$e'] to ['a', 'b', 'c', 'd', 'e'] </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-pandas t-replace t-dataframe t-rename"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/pandas" class="post-tag flex--item mt0 js-tagname-pandas" title="show questions tagged 'pandas'" aria-label="show questions tagged 'pandas'" rel="tag" aria-labelledby="tag-pandas-tooltip-container">pandas</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/replace" class="post-tag flex--item mt0 js-tagname-replace" title="show questions tagged 'replace'" aria-label="show questions tagged 'replace'" rel="tag" aria-labelledby="tag-replace-tooltip-container">replace</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/dataframe" class="post-tag flex--item mt0 js-tagname-dataframe" title="show questions tagged 'dataframe'" aria-label="show questions tagged 'dataframe'" rel="tag" aria-labelledby="tag-dataframe-tooltip-container">dataframe</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/rename" class="post-tag flex--item mt0 js-tagname-rename" title="show questions tagged 'rename'" aria-label="show questions tagged 'rename'" rel="tag" aria-labelledby="tag-rename-tooltip-container">rename</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/1504276/user1504276" class="s-avatar s-avatar__16 s-user-card--avatar" data-user-id="1504276"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/a313b37581ebc8dc85792e388397812f?s=32&amp;d=identicon&amp;r=PG" alt="user1504276's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/1504276/user1504276" class="flex--item">user1504276</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 28,015" dir="ltr">28k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2012-07-05 14:21:15Z" class="relativetime">Jul 5, 2012 at 14:21</span></time> </div> </div> </div> </div> <div id="question-summary-11277432" class="s-post-summary js-post-summary" data-post-id="11277432" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 2753"> <span class="s-post-summary--stats-item-number">2753</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">11</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="2573378 views"> <span class="s-post-summary--stats-item-number">2.6m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/11277432/how-can-i-remove-a-key-from-a-python-dictionary" class="s-link">How can I remove a key from a Python dictionary?</a> </h3> <div class="s-post-summary--content-excerpt"> I want to remove a key from a dictionary if it is present. I currently use this code: if key in my_dict: del my_dict[key] Without the if statement, the code will raise KeyError if the key is not ... </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-dictionary t-unset"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/dictionary" class="post-tag flex--item mt0 js-tagname-dictionary" title="show questions tagged 'dictionary'" aria-label="show questions tagged 'dictionary'" rel="tag" aria-labelledby="tag-dictionary-tooltip-container">dictionary</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/unset" class="post-tag flex--item mt0 js-tagname-unset" title="show questions tagged 'unset'" aria-label="show questions tagged 'unset'" rel="tag" aria-labelledby="tag-unset-tooltip-container">unset</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/692499/tony" class="s-avatar s-avatar__16 s-user-card--avatar" data-user-id="692499"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/7757ce52a52d5696a160372ca41742d6?s=32&amp;d=identicon&amp;r=PG" alt="Tony's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/692499/tony" class="flex--item">Tony</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 35,891" dir="ltr">35.9k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2012-06-30 20:27:59Z" class="relativetime">Jun 30, 2012 at 20:27</span></time> </div> </div> </div> </div> <div id="question-summary-379906" class="s-post-summary js-post-summary" data-post-id="379906" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 2681"> <span class="s-post-summary--stats-item-number">2681</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">32</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="4639172 views"> <span class="s-post-summary--stats-item-number">4.6m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/379906/how-do-i-parse-a-string-to-a-float-or-int" class="s-link">How do I parse a string to a float or int?</a> </h3> <div class="s-post-summary--content-excerpt"> How can I convert a str to float? &quot;545.2222&quot; → 545.2222 How can I convert a str to int? &quot;31&quot; → 31 For the reverse, see Convert integer to string in Python and ... </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-parsing t-floating-point t-type-conversion t-integer"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/parsing" class="post-tag flex--item mt0 js-tagname-parsing" title="show questions tagged 'parsing'" aria-label="show questions tagged 'parsing'" rel="tag" aria-labelledby="tag-parsing-tooltip-container">parsing</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/floating-point" class="post-tag flex--item mt0 js-tagname-floating-point" title="show questions tagged 'floating-point'" aria-label="show questions tagged 'floating-point'" rel="tag" aria-labelledby="tag-floating-point-tooltip-container">floating-point</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/type-conversion" class="post-tag flex--item mt0 js-tagname-type-conversion" title="show questions tagged 'type-conversion'" aria-label="show questions tagged 'type-conversion'" rel="tag" aria-labelledby="tag-type-conversion-tooltip-container">type-conversion</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/integer" class="post-tag flex--item mt0 js-tagname-integer" title="show questions tagged 'integer'" aria-label="show questions tagged 'integer'" rel="tag" aria-labelledby="tag-integer-tooltip-container">integer</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/30529/tristan-havelick" class="s-avatar s-avatar__16 s-user-card--avatar js-user-hover-target" data-user-id="30529"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/f3a3491c1c83e8c62151752162184627?s=32&amp;d=identicon&amp;r=PG" alt="Tristan Havelick's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/30529/tristan-havelick" class="flex--item">Tristan Havelick</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 66,420" dir="ltr">66.4k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2008-12-19 01:52:26Z" class="relativetime">Dec 19, 2008 at 1:52</span></time> </div> </div> </div> </div> <div id="question-summary-1602934" class="s-post-summary js-post-summary" data-post-id="1602934" data-post-type-id="1"> <div class="s-post-summary--stats js-post-summary-stats"> <div class="s-post-summary--stats-item s-post-summary--stats-item__emphasized" title="Score of 2679"> <span class="s-post-summary--stats-item-number">2679</span> <span class="s-post-summary--stats-item-unit">votes</span> </div> <div class="s-post-summary--stats-item has-answers has-accepted-answer" title="one of the answers was accepted as the correct answer"> <svg aria-hidden="true" class="svg-icon iconCheckmarkSm" width="14" height="14" viewbox="0 0 14 14"><path d="M13 3.41 11.59 2 5 8.59 2.41 6 1 7.41l4 4 8-8Z"/></svg> <span class="s-post-summary--stats-item-number">16</span> <span class="s-post-summary--stats-item-unit">answers</span> </div> <div class="s-post-summary--stats-item is-supernova" title="5906948 views"> <span class="s-post-summary--stats-item-number">5.9m</span> <span class="s-post-summary--stats-item-unit">views</span> </div> </div> <div class="s-post-summary--content"> <h3 class="s-post-summary--content-title"> <a href="/web/20230306154331/https://stackoverflow.com/questions/1602934/check-if-a-given-key-already-exists-in-a-dictionary" class="s-link">Check if a given key already exists in a dictionary</a> </h3> <div class="s-post-summary--content-excerpt"> I wanted to test if a key exists in a dictionary before updating the value for the key. I wrote the following code: if 'key1' in dict.keys(): print "blah" else: print "boo" I think this is not ... </div> <div class="s-post-summary--meta"> <div class="s-post-summary--meta-tags tags js-tags t-python t-dictionary"> <ul class="ml0 list-ls-none js-post-tag-list-wrapper d-inline"><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python" class="post-tag flex--item mt0 js-tagname-python" title="show questions tagged 'python'" aria-label="show questions tagged 'python'" rel="tag" aria-labelledby="tag-python-tooltip-container">python</a></li><li class="d-inline mr4 js-post-tag-list-item"><a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/dictionary" class="post-tag flex--item mt0 js-tagname-dictionary" title="show questions tagged 'dictionary'" aria-label="show questions tagged 'dictionary'" rel="tag" aria-labelledby="tag-dictionary-tooltip-container">dictionary</a></li></ul> </div> <div class="s-user-card s-user-card__minimal"> <div aria-live="polite"> <a href="/web/20230306154331/https://stackoverflow.com/users/112850/mohan-gulati" class="s-avatar s-avatar__16 s-user-card--avatar" data-user-id="112850"> <div class="gravatar-wrapper-16"> <img src="https://web.archive.org/web/20230306154331im_/https://www.gravatar.com/avatar/9e9b6aa699adda116c6132adcde9d73f?s=32&amp;d=identicon&amp;r=PG" alt="Mohan Gulati's user avatar" width="16" , height="16" class="s-avatar--image"/> </div> </a> </div> <div class="s-user-card--info"> <div class="s-user-card--link d-flex gs4"> <a href="/web/20230306154331/https://stackoverflow.com/users/112850/mohan-gulati" class="flex--item">Mohan Gulati</a> </div> <ul class="s-user-card--awards"> <li class="s-user-card--rep"><span class="todo-no-class-here" title="reputation score 28,229" dir="ltr">28.2k</span></li> </ul> </div> <time class="s-user-card--time">asked <span title="2009-10-21 19:05:09Z" class="relativetime">Oct 21, 2009 at 19:05</span></time> </div> </div> </div> </div> </div> <br class="clear-both"/> <div class="s-pagination site1 themed pager float-left"> <div class="s-pagination--item is-selected" aria-current="&quot;page&quot;">1</div> <a class="s-pagination--item js-pagination-item" href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python?tab=votes&amp;page=2" rel="" title="Go to page 2">2</a> <a class="s-pagination--item js-pagination-item" href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python?tab=votes&amp;page=3" rel="" title="Go to page 3">3</a> <a class="s-pagination--item js-pagination-item" href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python?tab=votes&amp;page=4" rel="" title="Go to page 4">4</a> <a class="s-pagination--item js-pagination-item" href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python?tab=votes&amp;page=5" rel="" title="Go to page 5">5</a> <div class="s-pagination--item s-pagination--item__clear">…</div> <a class="s-pagination--item js-pagination-item" href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python?tab=votes&amp;page=42315" rel="" title="Go to page 42315">42315</a> <a class="s-pagination--item js-pagination-item" href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python?tab=votes&amp;page=2" rel="next" title="Go to page 2"> Next</a></div> </div> <div id="sidebar"> <div class="s-sidebarwidget s-sidebarwidget__yellow s-anchors s-anchors__grayscale mb16" data-tracker="cb=1"> <ul class="d-block p0 m0"> <li class="s-sidebarwidget--header s-sidebarwidget__small-bold-text d-flex fc-black-600 d:fc-black-900 bb bbw1"> The Overflow Blog </li> <li class="s-sidebarwidget--item d-flex px16"> <div class="flex--item1 fl-shrink0"> <svg aria-hidden="true" class="va-text-top svg-icon iconPencilSm" width="14" height="14" viewbox="0 0 14 14"><path d="m11.1 1.71 1.13 1.12c.2.2.2.51 0 .71L11.1 4.7 9.21 2.86l1.17-1.15c.2-.2.51-.2.71 0ZM2 10.12l6.37-6.43 1.88 1.88L3.88 12H2v-1.88Z"/></svg> </div> <div class="flex--item wmn0 ow-break-word"> <a href="https://web.archive.org/web/20230306154331/https://stackoverflow.blog/2023/03/03/the-nature-of-simulating-nature-a-qa-with-ibm-quantum-researcher-dr-jamie-garcia-ep-543/" class="js-gps-track" title="The nature of simulating nature: A Q&amp;A with IBM Quantum researcher Dr. Jamie Garcia (Ep. 543)" data-ga="[&quot;community bulletin board&quot;,&quot;The Overflow Blog&quot;,&quot;https://stackoverflow.blog/2023/03/03/the-nature-of-simulating-nature-a-qa-with-ibm-quantum-researcher-dr-jamie-garcia-ep-543/&quot;,null,null]" data-gps-track="communitybulletin.click({ priority: 1, position: 0 })">The nature of simulating nature: A Q&amp;A with IBM Quantum researcher Dr. Jamie...</a> </div> </li> <li class="s-sidebarwidget--item d-flex px16"> <div class="flex--item1 fl-shrink0"> <svg aria-hidden="true" class="va-text-top svg-icon iconPencilSm" width="14" height="14" viewbox="0 0 14 14"><path d="m11.1 1.71 1.13 1.12c.2.2.2.51 0 .71L11.1 4.7 9.21 2.86l1.17-1.15c.2-.2.51-.2.71 0ZM2 10.12l6.37-6.43 1.88 1.88L3.88 12H2v-1.88Z"/></svg> </div> <div class="flex--item wmn0 ow-break-word"> <a href="https://web.archive.org/web/20230306154331/https://stackoverflow.blog/2023/03/06/five-stack-exchange-sites-turned-ten-years-old-this-quarter/" class="js-gps-track" data-ga="[&quot;community bulletin board&quot;,&quot;The Overflow Blog&quot;,&quot;https://stackoverflow.blog/2023/03/06/five-stack-exchange-sites-turned-ten-years-old-this-quarter/&quot;,null,null]" data-gps-track="communitybulletin.click({ priority: 1, position: 1 })">Five Stack Exchange sites turned ten years-old this quarter!&#160;</a> </div> </li> <li class="s-sidebarwidget--header s-sidebarwidget__small-bold-text d-flex fc-black-600 d:fc-black-900 bb bbw1"> Featured on Meta </li> <li class="s-sidebarwidget--item d-flex px16"> <div class="flex--item1 fl-shrink0"> <div class="favicon favicon-stackexchangemeta" title="Meta Stack Exchange"></div> </div> <div class="flex--item wmn0 ow-break-word"> <a href="https://web.archive.org/web/20230306154331/https://meta.stackexchange.com/questions/386727/weve-added-a-necessary-cookies-only-option-to-the-cookie-consent-popup" class="js-gps-track" data-ga="[&quot;community bulletin board&quot;,&quot;Featured on Meta&quot;,&quot;https://meta.stackexchange.com/questions/386727/weve-added-a-necessary-cookies-only-option-to-the-cookie-consent-popup&quot;,null,null]" data-gps-track="communitybulletin.click({ priority: 3, position: 2 })">We&#39;ve added a &quot;Necessary cookies only&quot; option to the cookie consent popup</a> </div> </li> <li class="s-sidebarwidget--item d-flex px16"> <div class="flex--item1 fl-shrink0"> <div class="favicon favicon-stackoverflowmeta" title="Meta Stack Overflow"></div> </div> <div class="flex--item wmn0 ow-break-word"> <a href="https://web.archive.org/web/20230306154331/https://meta.stackoverflow.com/questions/423429/launching-the-ci-cd-and-r-collectives-and-community-editing-features-for-article" class="js-gps-track" title="Launching the CI/CD and R Collectives and community editing features for articles" data-ga="[&quot;community bulletin board&quot;,&quot;Featured on Meta&quot;,&quot;https://meta.stackoverflow.com/questions/423429/launching-the-ci-cd-and-r-collectives-and-community-editing-features-for-article&quot;,null,null]" data-gps-track="communitybulletin.click({ priority: 6, position: 3 })">Launching the CI/CD and R Collectives and community editing features for...</a> </div> </li> <li class="s-sidebarwidget--item d-flex px16"> <div class="flex--item1 fl-shrink0"> <div class="favicon favicon-stackoverflowmeta" title="Meta Stack Overflow"></div> </div> <div class="flex--item wmn0 ow-break-word"> <a href="https://web.archive.org/web/20230306154331/https://meta.stackoverflow.com/questions/345643/the-amazon-tag-is-being-burninated" class="js-gps-track" data-ga="[&quot;community bulletin board&quot;,&quot;Featured on Meta&quot;,&quot;https://meta.stackoverflow.com/questions/345643/the-amazon-tag-is-being-burninated&quot;,null,null]" data-gps-track="communitybulletin.click({ priority: 6, position: 4 })">The [amazon] tag is being burninated</a> </div> </li> <li class="s-sidebarwidget--item d-flex px16"> <div class="flex--item1 fl-shrink0"> <div class="favicon favicon-stackoverflowmeta" title="Meta Stack Overflow"></div> </div> <div class="flex--item wmn0 ow-break-word"> <a href="https://web.archive.org/web/20230306154331/https://meta.stackoverflow.com/questions/421831/temporary-policy-chatgpt-is-banned" class="js-gps-track" data-ga="[&quot;community bulletin board&quot;,&quot;Featured on Meta&quot;,&quot;https://meta.stackoverflow.com/questions/421831/temporary-policy-chatgpt-is-banned&quot;,null,null]" data-gps-track="communitybulletin.click({ priority: 6, position: 5 })">Temporary policy: ChatGPT is banned</a> </div> </li> <li class="s-sidebarwidget--item d-flex px16"> <div class="flex--item1 fl-shrink0"> <div class="favicon favicon-stackoverflowmeta" title="Meta Stack Overflow"></div> </div> <div class="flex--item wmn0 ow-break-word"> <a href="https://web.archive.org/web/20230306154331/https://meta.stackoverflow.com/questions/423469/staging-ground-beta-1-recap-and-reviewers-needed-for-beta-2" class="js-gps-track" data-ga="[&quot;community bulletin board&quot;,&quot;Featured on Meta&quot;,&quot;https://meta.stackoverflow.com/questions/423469/staging-ground-beta-1-recap-and-reviewers-needed-for-beta-2&quot;,null,null]" data-gps-track="communitybulletin.click({ priority: 6, position: 6 })">Staging Ground Beta 1 Recap, and Reviewers needed for Beta 2</a> </div> </li> </ul> </div> <div class="js-sidebar-zone" style="min-height: 300px;"> <div class="js-zone-container zone-container-sidebar"> <div id="dfp-tsb" class="everyonelovesstackoverflow everyoneloves__top-sidebar"></div> <div class="js-report-ad-button-container " style="width: 300px"></div> </div> <div class="js-zone-container zone-container-sidebar"> <div id="dfp-msb" class="everyonelovesstackoverflow everyoneloves__mid-sidebar"></div> <div class="js-report-ad-button-container " style="width: 300px"></div> </div> <div id="hireme"></div> </div> <div class="module js-gps-related-tags"> <h2 id="h-related-tags" class="fc-black-700">Related Tags</h2> <div data-name="pandas"> <a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python+pandas" class="post-tag no-tag-menu" title="show questions tagged 'python pandas'" aria-label="show questions tagged 'python pandas'" rel="tag">pandas</a>&nbsp;<span class="item-multiplier"><span class="item-multiplier-x">&times;</span>&nbsp;<span class="item-multiplier-count">237765</span> </span> </div> <div data-name="python-3.x"> <a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python+python-3.x" class="post-tag no-tag-menu" title="show questions tagged 'python python-3.x'" aria-label="show questions tagged 'python python-3.x'" rel="tag">python-3.x</a>&nbsp;<span class="item-multiplier"><span class="item-multiplier-x">&times;</span>&nbsp;<span class="item-multiplier-count">200659</span> </span> </div> <div data-name="django"> <a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python+django" class="post-tag no-tag-menu" title="show questions tagged 'python django'" aria-label="show questions tagged 'python django'" rel="tag">django</a>&nbsp;<span class="item-multiplier"><span class="item-multiplier-x">&times;</span>&nbsp;<span class="item-multiplier-count">155063</span> </span> </div> <div data-name="numpy"> <a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python+numpy" class="post-tag no-tag-menu" title="show questions tagged 'python numpy'" aria-label="show questions tagged 'python numpy'" rel="tag">numpy</a>&nbsp;<span class="item-multiplier"><span class="item-multiplier-x">&times;</span>&nbsp;<span class="item-multiplier-count">97716</span> </span> </div> <div data-name="dataframe"> <a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python+dataframe" class="post-tag no-tag-menu" title="show questions tagged 'python dataframe'" aria-label="show questions tagged 'python dataframe'" rel="tag">dataframe</a>&nbsp;<span class="item-multiplier"><span class="item-multiplier-x">&times;</span>&nbsp;<span class="item-multiplier-count">86013</span> </span> </div> <div data-name="list"> <a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python+list" class="post-tag no-tag-menu" title="show questions tagged 'python list'" aria-label="show questions tagged 'python list'" rel="tag">list</a>&nbsp;<span class="item-multiplier"><span class="item-multiplier-x">&times;</span>&nbsp;<span class="item-multiplier-count">69644</span> </span> </div> <div data-name="python-2.7"> <a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python+python-2.7" class="post-tag no-tag-menu" title="show questions tagged 'python python-2.7'" aria-label="show questions tagged 'python python-2.7'" rel="tag">python-2.7</a>&nbsp;<span class="item-multiplier"><span class="item-multiplier-x">&times;</span>&nbsp;<span class="item-multiplier-count">63144</span> </span> </div> <div data-name="matplotlib"> <a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python+matplotlib" class="post-tag no-tag-menu" title="show questions tagged 'python matplotlib'" aria-label="show questions tagged 'python matplotlib'" rel="tag">matplotlib</a>&nbsp;<span class="item-multiplier"><span class="item-multiplier-x">&times;</span>&nbsp;<span class="item-multiplier-count">60177</span> </span> </div> <div data-name="selenium-webdriver"> <a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python+selenium-webdriver" class="post-tag no-tag-menu" title="show questions tagged 'python selenium-webdriver'" aria-label="show questions tagged 'python selenium-webdriver'" rel="tag">selenium-webdriver</a>&nbsp;<span class="item-multiplier"><span class="item-multiplier-x">&times;</span>&nbsp;<span class="item-multiplier-count">50158</span> </span> </div> <div data-name="tensorflow"> <a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python+tensorflow" class="post-tag no-tag-menu" title="show questions tagged 'python tensorflow'" aria-label="show questions tagged 'python tensorflow'" rel="tag">tensorflow</a>&nbsp;<span class="item-multiplier"><span class="item-multiplier-x">&times;</span>&nbsp;<span class="item-multiplier-count">46970</span> </span> </div> <div class="dno js-hidden" data-name="dictionary"> <a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python+dictionary" class="post-tag no-tag-menu" title="show questions tagged 'python dictionary'" aria-label="show questions tagged 'python dictionary'" rel="tag">dictionary</a>&nbsp;<span class="item-multiplier"><span class="item-multiplier-x">&times;</span>&nbsp;<span class="item-multiplier-count">46550</span> </span> </div> <div class="dno js-hidden" data-name="tkinter"> <a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python+tkinter" class="post-tag no-tag-menu" title="show questions tagged 'python tkinter'" aria-label="show questions tagged 'python tkinter'" rel="tag">tkinter</a>&nbsp;<span class="item-multiplier"><span class="item-multiplier-x">&times;</span>&nbsp;<span class="item-multiplier-count">43372</span> </span> </div> <div class="dno js-hidden" data-name="flask"> <a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python+flask" class="post-tag no-tag-menu" title="show questions tagged 'python flask'" aria-label="show questions tagged 'python flask'" rel="tag">flask</a>&nbsp;<span class="item-multiplier"><span class="item-multiplier-x">&times;</span>&nbsp;<span class="item-multiplier-count">40091</span> </span> </div> <div class="dno js-hidden" data-name="regex"> <a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python+regex" class="post-tag no-tag-menu" title="show questions tagged 'python regex'" aria-label="show questions tagged 'python regex'" rel="tag">regex</a>&nbsp;<span class="item-multiplier"><span class="item-multiplier-x">&times;</span>&nbsp;<span class="item-multiplier-count">35249</span> </span> </div> <div class="dno js-hidden" data-name="arrays"> <a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python+arrays" class="post-tag no-tag-menu" title="show questions tagged 'python arrays'" aria-label="show questions tagged 'python arrays'" rel="tag">arrays</a>&nbsp;<span class="item-multiplier"><span class="item-multiplier-x">&times;</span>&nbsp;<span class="item-multiplier-count">33599</span> </span> </div> <div class="dno js-hidden" data-name="json"> <a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python+json" class="post-tag no-tag-menu" title="show questions tagged 'python json'" aria-label="show questions tagged 'python json'" rel="tag">json</a>&nbsp;<span class="item-multiplier"><span class="item-multiplier-x">&times;</span>&nbsp;<span class="item-multiplier-count">33000</span> </span> </div> <div class="dno js-hidden" data-name="csv"> <a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python+csv" class="post-tag no-tag-menu" title="show questions tagged 'python csv'" aria-label="show questions tagged 'python csv'" rel="tag">csv</a>&nbsp;<span class="item-multiplier"><span class="item-multiplier-x">&times;</span>&nbsp;<span class="item-multiplier-count">32646</span> </span> </div> <div class="dno js-hidden" data-name="string"> <a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python+string" class="post-tag no-tag-menu" title="show questions tagged 'python string'" aria-label="show questions tagged 'python string'" rel="tag">string</a>&nbsp;<span class="item-multiplier"><span class="item-multiplier-x">&times;</span>&nbsp;<span class="item-multiplier-count">31750</span> </span> </div> <div class="dno js-hidden" data-name="web-scraping"> <a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python+web-scraping" class="post-tag no-tag-menu" title="show questions tagged 'python web-scraping'" aria-label="show questions tagged 'python web-scraping'" rel="tag">web-scraping</a>&nbsp;<span class="item-multiplier"><span class="item-multiplier-x">&times;</span>&nbsp;<span class="item-multiplier-count">27712</span> </span> </div> <div class="dno js-hidden" data-name="beautifulsoup"> <a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python+beautifulsoup" class="post-tag no-tag-menu" title="show questions tagged 'python beautifulsoup'" aria-label="show questions tagged 'python beautifulsoup'" rel="tag">beautifulsoup</a>&nbsp;<span class="item-multiplier"><span class="item-multiplier-x">&times;</span>&nbsp;<span class="item-multiplier-count">27171</span> </span> </div> <div class="dno js-hidden" data-name="html"> <a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python+html" class="post-tag no-tag-menu" title="show questions tagged 'python html'" aria-label="show questions tagged 'python html'" rel="tag">html</a>&nbsp;<span class="item-multiplier"><span class="item-multiplier-x">&times;</span>&nbsp;<span class="item-multiplier-count">27140</span> </span> </div> <div class="dno js-hidden" data-name="opencv"> <a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python+opencv" class="post-tag no-tag-menu" title="show questions tagged 'python opencv'" aria-label="show questions tagged 'python opencv'" rel="tag">opencv</a>&nbsp;<span class="item-multiplier"><span class="item-multiplier-x">&times;</span>&nbsp;<span class="item-multiplier-count">27003</span> </span> </div> <div class="dno js-hidden" data-name="keras"> <a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python+keras" class="post-tag no-tag-menu" title="show questions tagged 'python keras'" aria-label="show questions tagged 'python keras'" rel="tag">keras</a>&nbsp;<span class="item-multiplier"><span class="item-multiplier-x">&times;</span>&nbsp;<span class="item-multiplier-count">26350</span> </span> </div> <div class="dno js-hidden" data-name="machine-learning"> <a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python+machine-learning" class="post-tag no-tag-menu" title="show questions tagged 'python machine-learning'" aria-label="show questions tagged 'python machine-learning'" rel="tag">machine-learning</a>&nbsp;<span class="item-multiplier"><span class="item-multiplier-x">&times;</span>&nbsp;<span class="item-multiplier-count">26034</span> </span> </div> <div class="dno js-hidden" data-name="scikit-learn"> <a href="/web/20230306154331/https://stackoverflow.com/questions/tagged/python+scikit-learn" class="post-tag no-tag-menu" title="show questions tagged 'python scikit-learn'" aria-label="show questions tagged 'python scikit-learn'" rel="tag">scikit-learn</a>&nbsp;<span class="item-multiplier"><span class="item-multiplier-x">&times;</span>&nbsp;<span class="item-multiplier-count">21346</span> </span> </div> <a href="#" class="show-more js-show-more js-gps-track" data-gps-track="related_tags.click({ item_type:2 })"> more related tags </a> <script> StackExchange.ready(function () { var $div = $('#h-related-tags').parent(); $div.find('.js-show-more').click(function () { $div.find('.js-hidden').show(); $(this).remove(); return false; }); }); </script> </div> <div id="hot-network-questions" class="module tex2jax_ignore"> <h4> <a href="https://web.archive.org/web/20230306154331/https://stackexchange.com/questions?tab=hot" class="js-gps-track s-link s-link__inherit" data-gps-track="posts_hot_network.click({ item_type:1, location:9 })"> Hot Network Questions </a> </h4> <ul> <li> <div class="favicon favicon-philosophy" title="Philosophy Stack Exchange"></div><a href="https://web.archive.org/web/20230306154331/https://philosophy.stackexchange.com/questions/97570/should-i-put-my-dog-down-to-help-the-homeless" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:9, target_site:265 }); posts_hot_network.click({ item_type:2, location:9 })"> Should I put my dog down to help the homeless? </a> </li> <li> <div class="favicon favicon-latin" title="Latin Language Stack Exchange"></div><a href="https://web.archive.org/web/20230306154331/https://latin.stackexchange.com/questions/20599/videre-is-to-spectare-what-audire-is-to" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:9, target_site:644 }); posts_hot_network.click({ item_type:2, location:9 })"> &quot;Videre&quot; is to &quot;spectare&quot; what &quot;audire&quot; is to...? </a> </li> <li> <div class="favicon favicon-superuser" title="Super User"></div><a href="https://web.archive.org/web/20230306154331/https://superuser.com/questions/1771960/should-the-sticker-on-top-of-a-hdd-be-peeled" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:9, target_site:3 }); posts_hot_network.click({ item_type:2, location:9 })"> Should the sticker on top of a HDD be peeled? </a> </li> <li> <div class="favicon favicon-worldbuilding" title="Worldbuilding Stack Exchange"></div><a href="https://web.archive.org/web/20230306154331/https://worldbuilding.stackexchange.com/questions/243796/how-would-zombies-affect-trench-warfare" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:9, target_site:579 }); posts_hot_network.click({ item_type:2, location:9 })"> How would zombies affect trench warfare? </a> </li> <li> <div class="favicon favicon-aviation" title="Aviation Stack Exchange"></div><a href="https://web.archive.org/web/20230306154331/https://aviation.stackexchange.com/questions/97901/is-it-suspicious-or-odd-to-stand-by-the-gate-of-a-ga-airport-watching-the-planes" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:9, target_site:528 }); posts_hot_network.click({ item_type:2, location:9 })"> Is it suspicious or odd to stand by the gate of a GA airport watching the planes? </a> </li> <li> <div class="favicon favicon-travel" title="Travel Stack Exchange"></div><a href="https://web.archive.org/web/20230306154331/https://travel.stackexchange.com/questions/179814/questions-about-bringing-spices-or-nuts-to-new-zealand" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:9, target_site:273 }); posts_hot_network.click({ item_type:2, location:9 })"> Questions about bringing spices or nuts to New Zealand </a> </li> <li> <div class="favicon favicon-codereview" title="Code Review Stack Exchange"></div><a href="https://web.archive.org/web/20230306154331/https://codereview.stackexchange.com/questions/283744/serialization-and-deserialization-doubly-linked-list-with-pointer-to-random-node" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:9, target_site:196 }); posts_hot_network.click({ item_type:2, location:9 })"> Serialization and deserialization doubly-linked list with pointer to random node on c&#x2B;&#x2B; </a> </li> <li> <div class="favicon favicon-scifi" title="Science Fiction &amp; Fantasy Stack Exchange"></div><a href="https://web.archive.org/web/20230306154331/https://scifi.stackexchange.com/questions/273725/was-kips-defiance-relevant-to-the-galactics-decision" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:9, target_site:186 }); posts_hot_network.click({ item_type:2, location:9 })"> Was Kip&#x27;s defiance relevant to the Galactics&#x27; decision? </a> </li> <li> <div class="favicon favicon-mathematica" title="Mathematica Stack Exchange"></div><a href="https://web.archive.org/web/20230306154331/https://mathematica.stackexchange.com/questions/281925/how-can-one-build-this-kind-of-graphics-what-kind-of-plot-is-it" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:9, target_site:387 }); posts_hot_network.click({ item_type:2, location:9 })"> How can one build this kind of graphics? What kind of plot is it? </a> </li> <li> <div class="favicon favicon-gis" title="Geographic Information Systems Stack Exchange"></div><a href="https://web.archive.org/web/20230306154331/https://gis.stackexchange.com/questions/454455/displaying-label-if-field-contains-x-or-y-value-in-qgis" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:9, target_site:79 }); posts_hot_network.click({ item_type:2, location:9 })"> Displaying label if field contains &#x27;X&#x27; or &#x27;Y&#x27; value in QGIS </a> </li> <li> <div class="favicon favicon-opensource" title="Open Source Stack Exchange"></div><a href="https://web.archive.org/web/20230306154331/https://opensource.stackexchange.com/questions/13806/which-type-of-license-doesnt-require-attribution-in-github-projects" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:9, target_site:619 }); posts_hot_network.click({ item_type:2, location:9 })"> Which type of license doesn&#x27;t require attribution in Github projects? </a> </li> <li> <div class="favicon favicon-hermeneutics" title="Biblical Hermeneutics Stack Exchange"></div><a href="https://web.archive.org/web/20230306154331/https://hermeneutics.stackexchange.com/questions/82964/does-matt-58-also-tell-us-that-willing-unrepentant-sin-causes-doubt" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:9, target_site:320 }); posts_hot_network.click({ item_type:2, location:9 })"> Does Matt. 5:8 also tell us that willing unrepentant sin causes doubt? </a> </li> <li class="dno js-hidden"> <div class="favicon favicon-diy" title="Home Improvement Stack Exchange"></div><a href="https://web.archive.org/web/20230306154331/https://diy.stackexchange.com/questions/268239/a-plastic-tab-tag-stuck-out-of-the-ge-dryer-drum-gap-does-anyone-know-what-it-i" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:9, target_site:73 }); posts_hot_network.click({ item_type:2, location:9 })"> A plastic tab/tag stuck out of the GE dryer drum gap. Does anyone know what it is, if it is a part of the dryer, and if so how I can fix it? </a> </li> <li class="dno js-hidden"> <div class="favicon favicon-ell" title="English Language Learners Stack Exchange"></div><a href="https://web.archive.org/web/20230306154331/https://ell.stackexchange.com/questions/333708/is-or-are-for-two-uncountable-words" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:9, target_site:481 }); posts_hot_network.click({ item_type:2, location:9 })"> &quot;Is&quot; or &quot;are&quot; for two uncountable words? </a> </li> <li class="dno js-hidden"> <div class="favicon favicon-electronics" title="Electrical Engineering Stack Exchange"></div><a href="https://web.archive.org/web/20230306154331/https://electronics.stackexchange.com/questions/657549/heating-resistor-low-current-high-temperature" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:9, target_site:135 }); posts_hot_network.click({ item_type:2, location:9 })"> Heating resistor - low current, high temperature </a> </li> <li class="dno js-hidden"> <div class="favicon favicon-music" title="Music: Practice &amp; Theory Stack Exchange"></div><a href="https://web.archive.org/web/20230306154331/https://music.stackexchange.com/questions/128832/combine-notes-and-lyrics-into-a-variable" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:9, target_site:240 }); posts_hot_network.click({ item_type:2, location:9 })"> Combine notes and lyrics into a variable </a> </li> <li class="dno js-hidden"> <div class="favicon favicon-matheducators" title="Mathematics Educators Stack Exchange"></div><a href="https://web.archive.org/web/20230306154331/https://matheducators.stackexchange.com/questions/26199/how-do-should-administrators-estimate-the-cost-of-producing-an-online-introducto" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:9, target_site:548 }); posts_hot_network.click({ item_type:2, location:9 })"> How do/should administrators estimate the cost of producing an online introductory mathematics class? </a> </li> <li class="dno js-hidden"> <div class="favicon favicon-judaism" title="Mi Yodeya"></div><a href="https://web.archive.org/web/20230306154331/https://judaism.stackexchange.com/questions/133528/the-3-attributes-of-abraham-avinu-mentioned-in-artscrolls-midrash-rabbah-insigh" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:9, target_site:248 }); posts_hot_network.click({ item_type:2, location:9 })"> The 3 attributes of Abraham Avinu mentioned in Artscroll&#x27;s Midrash Rabbah Insights section? </a> </li> <li class="dno js-hidden"> <div class="favicon favicon-astronomy" title="Astronomy Stack Exchange"></div><a href="https://web.archive.org/web/20230306154331/https://astronomy.stackexchange.com/questions/53075/how-would-dark-matter-subject-only-to-gravity-behave" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:9, target_site:514 }); posts_hot_network.click({ item_type:2, location:9 })"> How would &quot;dark matter&quot;, subject only to gravity, behave? </a> </li> <li class="dno js-hidden"> <div class="favicon favicon-scifi" title="Science Fiction &amp; Fantasy Stack Exchange"></div><a href="https://web.archive.org/web/20230306154331/https://scifi.stackexchange.com/questions/273717/what-are-the-stargate-dial-home-device-symbols-used-to-dial-earth-from-atlantis" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:9, target_site:186 }); posts_hot_network.click({ item_type:2, location:9 })"> What are the Stargate dial home device symbols used to dial Earth from Atlantis? </a> </li> <li class="dno js-hidden"> <div class="favicon favicon-tex" title="TeX - LaTeX Stack Exchange"></div><a href="https://web.archive.org/web/20230306154331/https://tex.stackexchange.com/questions/678373/multiple-tables-with-red-color-curly-brackets" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:9, target_site:85 }); posts_hot_network.click({ item_type:2, location:9 })"> Multiple tables with red color curly brackets </a> </li> <li class="dno js-hidden"> <div class="favicon favicon-english" title="English Language &amp; Usage Stack Exchange"></div><a href="https://web.archive.org/web/20230306154331/https://english.stackexchange.com/questions/604303/in-england-why-are-some-high-schools-called-hospitals" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:9, target_site:97 }); posts_hot_network.click({ item_type:2, location:9 })"> In England, why are some high schools called hospitals? </a> </li> <li class="dno js-hidden"> <div class="favicon favicon-magento" title="Magento Stack Exchange"></div><a href="https://web.archive.org/web/20230306154331/https://magento.stackexchange.com/questions/365097/override-item-layout-of-credit-memo-in-email-template-and-add-new-column" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:9, target_site:479 }); posts_hot_network.click({ item_type:2, location:9 })"> Override item layout of credit memo in email template and add new column </a> </li> <li class="dno js-hidden"> <div class="favicon favicon-opensource" title="Open Source Stack Exchange"></div><a href="https://web.archive.org/web/20230306154331/https://opensource.stackexchange.com/questions/13788/my-code-is-gpl-licensed-can-i-issue-a-license-to-have-my-code-be-distributed-in" class="js-gps-track question-hyperlink mb0" data-gps-track="site.switch({ item_type:9, target_site:619 }); posts_hot_network.click({ item_type:2, location:9 })"> My code is GPL licensed, can I issue a license to have my code be distributed in a specific MIT licensed project? </a> </li> </ul> <a href="#" class="show-more js-show-more js-gps-track" data-gps-track="posts_hot_network.click({ item_type:3, location:9 })"> more hot questions </a> </div> <div id="feed-link" class="js-feed-link"> <a href="/web/20230306154331/https://stackoverflow.com/feeds/tag?tagnames=python&amp;sort=votes" title="The 30 highest scored python questions"> <svg aria-hidden="true" class="fc-orange-400 svg-icon iconRss" width="18" height="18" viewbox="0 0 18 18"><path d="M3 1a2 2 0 0 0-2 2v12c0 1.1.9 2 2 2h12a2 2 0 0 0 2-2V3a2 2 0 0 0-2-2H3Zm0 1.5c6.9 0 12.5 5.6 12.5 12.5H13C13 9.55 8.45 5 3 5V2.5Zm0 5c4.08 0 7.5 3.41 7.5 7.5H8c0-2.72-2.28-5-5-5V7.5Zm0 5c1.36 0 2.5 1.14 2.5 2.5H3v-2.5Z"/></svg> Highest scored python questions feed </a> </div> <aside class="s-modal js-feed-link-modal" tabindex="-1" role="dialog" aria-labelledby="feed-modal-title" aria-describedby="feed-modal-description" aria-hidden="true"> <div class="s-modal--dialog js-modal-dialog wmx4" role="document" data-controller="se-draggable"> <h1 class="s-modal--header fw-bold js-first-tabbable" id="feed-modal-title" data-se-draggable-target="handle" tabindex="0"> Subscribe to RSS </h1> <div class="d-flex gs4 gsy fd-column"> <div class="flex--item"> <label class="d-block s-label c-default" for="feed-url"> Highest scored python questions feed <p class="s-description mt2" id="feed-modal-description">To subscribe to this RSS feed, copy and paste this URL into your RSS reader.</p> </label> </div> <div class="d-flex ps-relative"> <input class="s-input" type="text" name="feed-url" id="feed-url" readonly="readonly" value="https://stackoverflow.com/feeds/tag?tagnames=python&amp;sort=votes"/> <svg aria-hidden="true" class="s-input-icon fc-orange-400 svg-icon iconRss" width="18" height="18" viewbox="0 0 18 18"><path d="M3 1a2 2 0 0 0-2 2v12c0 1.1.9 2 2 2h12a2 2 0 0 0 2-2V3a2 2 0 0 0-2-2H3Zm0 1.5c6.9 0 12.5 5.6 12.5 12.5H13C13 9.55 8.45 5 3 5V2.5Zm0 5c4.08 0 7.5 3.41 7.5 7.5H8c0-2.72-2.28-5-5-5V7.5Zm0 5c1.36 0 2.5 1.14 2.5 2.5H3v-2.5Z"/></svg> </div> </div> <a class="s-modal--close s-btn s-btn__muted js-modal-close js-last-tabbable" href="#" aria-label="Close"> <svg aria-hidden="true" class="svg-icon iconClearSm" width="14" height="14" viewbox="0 0 14 14"><path d="M12 3.41 10.59 2 7 5.59 3.41 2 2 3.41 5.59 7 2 10.59 3.41 12 7 8.41 10.59 12 12 10.59 8.41 7 12 3.41Z"/></svg> </a> </div> </aside> </div> </div> </div> <script type="text/javascript"> var cam = cam || { opt: {} }; var clcGamLoaderOptions = cam || { opt: {} }; var opt = clcGamLoaderOptions.opt; opt.omni = 'BwoLCP6N657ymM87EAUgAigBOgh8cHl0aG9ufEgAWhIJhj17OoJ5Do4R9WZtRyokkDh1sAC9TfthlpAz'; opt.sf = !0; opt.hb = !1; opt.ll = !0; opt.tlb_position = 0; opt.personalization_consent = !1; opt.targeting_consent = !1; opt.performance_consent = !1; opt.targeting = {Registered:['false'],'so-tag':['python'],'tag-reportable':['python'],'tag-non-reportable':['python']}; opt.adReportEnabled = !0; opt.adReportUrl = '/ads/report-ad'; opt.adReportText = 'Report this ad'; opt.adReportFileTypeErrorMessage = 'Please select a PNG or JPG file.'; opt.adReportFileSizeErrorMessage = 'The file must be under 2 MiB.'; opt.adReportErrorText = 'Error uploading ad report.'; opt.adReportThanksText = 'Thanks for your feedback. We’ll review this against our code of conduct and take action if necessary.'; opt.adReportLoginExpiredMessage = 'Your login session has expired, please login and try again.'; opt.adReportLoginErrorMessage = 'An error occurred when loading the report form - please try again'; opt.adReportModalClass = 'js-ad-report'; opt.requestGuid = '51d533ad-7932-4d8a-b69d-52c8f1db4f46'; opt.targeting.TargetingConsent = ['False_Passive']; const urlParams = new URLSearchParams(window.location.search); if (urlParams.has('dfptestads')) { const dfptestads = urlParams.get('dfptestads'); opt.targeting.DfpTestAds = dfptestads; } </script> <script>;(()=>{"use strict";var __webpack_modules__={23:(e,t,o)=>{o.d(t,{Z7:()=>l,eq:()=>r,kG:()=>n});const a=/^\/tags\//.test(location.pathname)||/^\/questions\/tagged\//.test(location.pathname)?"tag-pages":/^\/$/.test(location.pathname)||/^\/home/.test(location.pathname)?"home-page":"question-pages";let s=location.hostname;const i={slots:{lb:[[728,90]],mlb:[[728,90]],smlb:[[728,90]],bmlb:[[728,90]],sb:e=>"dfp-tsb"===e?[[300,250],[300,600]]:[[300,250]],"tag-sponsorship":[[730,135]],"mobile-below-question":[[320,50],[300,250]],msb:[[300,250],[300,600]],"talent-conversion-tracking":[[1,1]],"site-sponsorship":[[230,60]]},ids:{"dfp-tlb":"lb","dfp-mlb":"mlb","dfp-smlb":"smlb","dfp-bmlb":"bmlb","dfp-tsb":"sb","dfp-isb":"sb","dfp-tag":"tag-sponsorship","dfp-msb":"msb","dfp-sspon":"site-sponsorship","dfp-m-aq":"mobile-below-question"},idsToExcludeFromAdReports:["dfp-sspon"]};function n(){return Object.keys(i.ids)}function r(e){return i.idsToExcludeFromAdReports.indexOf(e)<0}function l(e){var t=e.split("_")[0];const o=i.ids[t];let n=i.slots[o];return"function"==typeof n&&(n=n(t)),{path:`/248424177/${s}/${o}/${a}`,sizes:n,zone:o}}},865:(e,t,o)=>{function a(e){return"string"==typeof e?document.getElementById(e):e}function s(e){return!!(e=a(e))&&"none"===getComputedStyle(e).display}function i(e){return!s(e)}function n(e){return!!e}function r(e){return/^\s*$/.test(a(e).innerHTML)}function l(e){const{style:t}=e;t.height=t.maxHeight=t.minHeight="auto",t.display="none"}function d(e){const{style:t}=e;t.height=t.maxHeight=t.minHeight="auto",t.display="none",[].forEach.call(e.children,d)}function c(e){const{style:t}=e;t.height=t.maxHeight=t.minHeight="auto",t.removeProperty("display")}function p(e){const t=document.createElement("script");t.src=e,document.body.appendChild(t)}function g(e){return o=e,(t=[]).push=function(e){return o(),delete this.push,this.push(e)},t;var t,o}function h(e){let t="function"==typeof HTMLTemplateElement;var o=document.createElement(t?"template":"div");return e=e.trim(),o.innerHTML=e,t?o.content.firstChild:o.firstChild}o.d(t,{$Z:()=>c,Bv:()=>h,Gx:()=>p,Nj:()=>a,QZ:()=>g,cf:()=>l,pn:()=>i,wo:()=>d,xb:()=>r,xj:()=>s,yb:()=>n})},763:(__unused_webpack_module,__webpack_exports__,__webpack_require__)=>{__webpack_require__.d(__webpack_exports__,{t:()=>AdReports});var _common_helper__WEBPACK_IMPORTED_MODULE_2__=__webpack_require__(865),_console__WEBPACK_IMPORTED_MODULE_1__=__webpack_require__(276),_ad_units__WEBPACK_IMPORTED_MODULE_0__=__webpack_require__(23);class AdReports{constructor(e,t){if(this.googletag=e,this.cam=t,this.allowedFileTypes=["image/png","image/jpg","image/jpeg"],this.ignoreValidation=!1,_console__WEBPACK_IMPORTED_MODULE_1__.cM("Ad reporting init"),this.cam=t,this.callOnButtonClick=e=>this.onButtonClick(e),this.googletag.pubads().addEventListener("slotRenderEnded",e=>this.handleSlotRendered(e)),Array.isArray(t.slotsRenderedEvents)){_console__WEBPACK_IMPORTED_MODULE_1__.cM("Adding report button to "+t.slotsRenderedEvents.length+" events that have transpired");for(var o=0;o<t.slotsRenderedEvents.length;o++)this.handleSlotRendered(t.slotsRenderedEvents[o])}}handleSlotRendered(e){if(e&&e.slot&&!e.isEmpty&&(e.creativeId||e.lineItemId||!e.isEmpty)){var t=e.slot.getSlotElementId();if(t){var o=document.getElementById(t);if(o)if((0,_ad_units__WEBPACK_IMPORTED_MODULE_0__.eq)(t)){var a=o?.closest(".js-zone-container")?.querySelector(".js-report-ad-button-container");a.append(this.createButton(e)),a.style.height="24px",_console__WEBPACK_IMPORTED_MODULE_1__.cM("Added report button to the bottom of "+t)}else _console__WEBPACK_IMPORTED_MODULE_1__.cM("Not adding report button to the bottom of "+t+": shouldHaveReportButton = false");else _console__WEBPACK_IMPORTED_MODULE_1__.cM("Not adding report button to the bottom of "+t+": resolved invalid adUnit element")}else _console__WEBPACK_IMPORTED_MODULE_1__.cM("Not adding report button to the bottom of element: invalid adUnitElementId")}else _console__WEBPACK_IMPORTED_MODULE_1__.cM("Not adding report button to the bottom of element: invalid SlotRenderEndedEvent")}async onButtonClick(e){e.preventDefault();let t=e.target;const o=t.dataset.modalUrl,a=t.dataset.googleEventData;return await this.loadModal(o,t,a),!1}createButton(e){let t=document.createElement("button");var o=JSON.stringify(e);return t.dataset.googleEventData=o,t.dataset.modalUrl=this.cam.opt.adReportUrl,t.dataset.adUnit=e.slot.getSlotElementId(),t.classList.add("js-report-ad","s-btn","s-btn__link","fs-fine","mt2","float-right"),t.append(document.createTextNode(this.cam.opt.adReportText)),t.removeEventListener("click",this.callOnButtonClick),t.addEventListener("click",this.callOnButtonClick),t}async loadModal(url,$link,googleEventData){try{await window.StackExchange.helpers.loadModal(url,{returnElements:window.$($link)}),this.initForm(googleEventData)}catch(e){var message="",response=e.responseText?eval(`(${e.responseText})`):null;message=response&&response.isLoggedOut?this.cam.opt.adReportLoginExpiredMessage:this.cam.opt.adReportLoginErrorMessage,window.StackExchange.helpers.showToast(message,{type:"danger"})}}removeModal(){window.StackExchange.helpers.closePopups(document.querySelectorAll("."+this.cam.opt.adReportModalClass),"dismiss")}initForm(e,t=!1){this.ignoreValidation=t,this.$form=document.querySelector(".js-ad-report-form"),this.$googleEventData=this.$form.querySelector(".js-json-data"),this.$adReportReasons=this.$form.querySelectorAll(".js-ad-report-reason"),this.$adReportReasonOther=this.$form.querySelector(".js-ad-report-reason-other"),this.$fileUploaderInput=this.$form.querySelector(".js-file-uploader-input"),this.$imageUploader=this.$form.querySelector(".js-image-uploader"),this.$clearImageUpload=this.$form.querySelector(".js-clear-image-upload"),this.$imageUploaderText=this.$form.querySelector(".js-image-uploader-text"),this.$imageUploaderPreview=this.$form.querySelector(".js-image-uploader-preview"),this.$fileErrorMessage=this.$form.querySelector(".js-file-error");const o=this.$form.querySelector(".js-drag-drop-enabled"),a=this.$form.querySelector(".js-drag-drop-disabled");this.$googleEventData.value=e,this.$adReportReasons.forEach((e,t)=>e.addEventListener("change",e=>{this.$adReportReasonOther.classList.toggle("d-none","3"!==e.target.value)})),this.$fileUploaderInput.addEventListener("change",()=>{this.validateFileInput()&&this.updateImagePreview(this.$fileUploaderInput.files)}),this.$clearImageUpload.addEventListener("click",e=>{e.preventDefault(),this.clearImageUpload()});try{this.$fileUploaderInput[0].value="",this.$imageUploader.addEventListener("dragenter dragover dragleave drop",this.preventDefaults),this.$imageUploader.addEventListener("dragenter dragover",this.handleDragStart),this.$imageUploader.addEventListener("dragleave drop",this.handleDragEnd),this.$imageUploader.addEventListener("drop",this.handleDrop)}catch(e){o.classList.add("d-none"),a.classList.remove("d-none")}this.$form.removeEventListener("",this.handleDragEnd),this.$form.addEventListener("submit",async e=>(e.preventDefault(),this.submitForm(),!1))}clearImageUpload(){this.$fileUploaderInput.value="",this.$imageUploaderPreview.setAttribute("src",""),this.$imageUploaderPreview.classList.add("d-none"),this.$clearImageUpload.classList.add("d-none"),this.$imageUploaderText.classList.remove("d-none"),this.$imageUploader.classList.add("p16","ba","bas-dashed","bc-black-100")}preventDefaults(e){e.preventDefault(),e.stopPropagation()}handleDragStart(e){this.$imageUploader.classList.remove("bas-dashed"),this.$imageUploader.classList.add("bas-solid","bc-black-100")}handleDragEnd(e){this.$imageUploader.classList.remove("bas-solid","bc-black-100"),this.$imageUploader.classList.add("bas-dashed")}handleDrop(e){var t=e.originalEvent.dataTransfer.files;FileReader&&t&&1===t.length&&(this.$fileUploaderInput.files=t,this.validateFileInput()&&this.updateImagePreview(t))}setError(e){this.$fileErrorMessage.parentElement.classList.toggle("has-error",e)}updateImagePreview(e){this.$imageUploader.classList.remove("p16","ba","bas-dashed","bc-black-100"),this.$clearImageUpload.classList.remove("d-none"),this.$imageUploaderText.classList.add("d-none");var t=new FileReader;t.onload=e=>{null!=e.target&&(this.$imageUploaderPreview.setAttribute("src",e.target.result),this.$imageUploaderPreview.classList.remove("d-none"))},t.readAsDataURL(e[0])}validateFileInput(){if(this.ignoreValidation)return!0;const e=this.cam.opt.adReportFileTypeErrorMessage,t=this.cam.opt.adReportFileSizeErrorMessage;if(null==this.$fileUploaderInput.files)return!1;var o=this.$fileUploaderInput.files[0];return null==o?(this.setError(!0),!1):this.allowedFileTypes.indexOf(o.type)<0?(this.$fileErrorMessage.textContent=e,this.$fileErrorMessage.classList.remove("d-none"),this.setError(!0),!1):o.size>2097152?(this.$fileErrorMessage.textContent=t,this.$fileErrorMessage.classList.remove("d-none"),this.setError(!0),!1):(this.$fileErrorMessage.classList.add("d-none"),this.setError(!1),!0)}async submitForm(){if(!this.validateFileInput())return!1;this.$form.querySelector("[type=submit]").setAttribute("disabled","true");var e=JSON.parse(this.$googleEventData.value||"{}");e.Reason=parseInt(this.$form.querySelector(".js-ad-report-reason:checked").value,10),e.Description=this.$adReportReasonOther.value,this.$googleEventData.value=JSON.stringify(e);var t=new FormData(this.$form);try{const e=await window.fetch(this.$form.getAttribute("action"),{method:this.$form.getAttribute("method"),body:t,cache:"no-cache"}),a=e.headers.get("content-type")||"",s=await e.text();if(!e.ok)throw new Error("response not valid");if(0===a.indexOf("text/html")){var o=(0,_common_helper__WEBPACK_IMPORTED_MODULE_2__.Bv)(s);const e=o?o.querySelector(".js-modal-content"):null;if(_console__WEBPACK_IMPORTED_MODULE_1__.cM("$popupContent"),_console__WEBPACK_IMPORTED_MODULE_1__.cM(e),!e)throw new Error(`Could not find .js-modal-content in response from ${this.$form.getAttribute("action")}`);document.querySelector(".js-modal-content").replaceWith(e)}else window.StackExchange.helpers.showToast(this.cam.opt.adReportThanksText,{type:"success"}),this.removeModal()}catch(e){window.StackExchange.helpers.showToast(this.cam.opt.adReportErrorText,{type:"danger"})}finally{let e=this.$form.querySelector("[type=submit]");e&&e.removeAttribute("disabled")}}}},276:(e,t,o)=>{function a(...e){}o.d(t,{cM:()=>a})}},__webpack_module_cache__={};function __webpack_require__(e){var t=__webpack_module_cache__[e];if(void 0!==t)return t.exports;var o=__webpack_module_cache__[e]={exports:{}};return __webpack_modules__[e](o,o.exports,__webpack_require__),o.exports}__webpack_require__.d=(e,t)=>{for(var o in t)__webpack_require__.o(t,o)&&!__webpack_require__.o(e,o)&&Object.defineProperty(e,o,{enumerable:!0,get:t[o]})},__webpack_require__.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t);var __webpack_exports__={};(()=>{var e=__webpack_require__(276),t=(e=>(e[e.Above=0]="Above",e[e.Below=1]="Below",e))(t||{});const o=Object.assign({},{"lib":"https://web.archive.org/web/20230306154331/https://cdn.sstatic.net/clc/js/bundles/gam_loader_script/gam_loader_script.bundle.741.a1bd5bd69766c6c9192d.min.js","style":null,"u":null,"wa":true,"kt":2000,"tto":true,"h":"clc.stackoverflow.com","allowed":"^(((talent\\.)?stackoverflow)|(blog\\.codinghorror)|(.*\\.googlesyndication)|(serverfault|askubuntu)|([^\\.]+\\.stackexchange))\\.com$","wv":true,"al":false,"abd":true,"cpa_liid":[5882654614],"cpa_cid":[138377597667],"dp":false});var a=__webpack_require__(23),s=__webpack_require__(865),i=__webpack_require__(763);window.cam=new class{constructor(){this.gptImported=!1,this.collapsed={},e.cM("constructor"),this.clc_options=o,window.clcGamLoaderOptions?Object.assign(this,window.clcGamLoaderOptions):void 0===this.opt&&(this.opt=window.opt)}init(){if(e.cM("init"),void 0===this.opt)throw new Error("opt not set, required by GAM Loader");e.cM("setup message handler"),window.addEventListener("message",e=>{this.onmessage(e)}),this.opt.targeting&&this.opt.targeting.ProductVariant&&"SystemDefault"===this.opt.targeting.ProductVariant[0]&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?this.opt.targeting.ProductVariant="Dark":this.opt.targeting.ProductVariant="Light")}handleSlotRenderedNoAdReport(){if(googletag.pubads().addEventListener("slotRenderEnded",e=>this.applyExtraMarginBottom(e)),Array.isArray(this.slotsRenderedEvents))for(var e=0;e<this.slotsRenderedEvents.length;e++)this.applyExtraMarginBottom(this.slotsRenderedEvents[e])}onmessage(t){let o="omni";if(t.data&&("string"==typeof t.data||t.data instanceof String))if(0===t.data.indexOf("get-omni-")){e.cM("Recevied get-omni message, sending back omni");var a=t.source,i=this.opt.omni,n="string"==typeof i?i:"";a.postMessage([o,n,this.opt.requestGuid].join("|"),"*")}else if(0===t.data.indexOf("collapse-")){e.cM("Recevied collapse message, collapse ad iframe"),e.cM(t);for(var r=t.source.window,l=document.getElementsByTagName("IFRAME"),d=0;d<l.length;d++){var c=l[d];if(c.contentWindow==r)return void(0,s.wo)(c.parentElement.parentElement.parentElement)}}else if(0===t.data.indexOf("resize|")){e.cM("Recevied resize message, resize ad iframe"),e.cM(t);let o=this._getFrameByEvent(t),a=t.data.indexOf("|")+1,s=t.data.slice(a),i=parseFloat(s)+.5;e.cM("New iframe height "+i),o.height=i.toString(),o.parentElement.style.height=i.toString()+"px"}else if(0===t.data.indexOf("getmarkup|")){let o=t.data.indexOf("|")+1,a=t.data.slice(o);e.cM("Recevied get markup message: "+a);let s=this._getFrameByEvent(t).closest(".everyonelovesstackoverflow");const i=document.createElement("script");i.dataset.adZoneId=s.id,i.src=a,document.body.appendChild(i)}}placeInIframe(t,o){e.cM("Received markup result in main frame");let a=document.getElementById(t.dataset.adZoneId),s=a.querySelector("iframe");if("string"==typeof o.prefixToIframeHtml){let e=document.createElement("div");e.innerHTML=o.prefixToIframeHtml,a.prepend(e.querySelector("img"))}s.contentWindow.postMessage(["markup",JSON.stringify(o)].join("|"),"*")}_getFrameByEvent(e){return Array.from(document.getElementsByTagName("iframe")).filter(t=>t.contentWindow===e.source)[0]}classifyZoneIds(e){const t=e.map(s.Nj).filter(s.yb);return{eligible:t.filter(s.xb).filter(s.pn),ineligible:t.filter(s.xj)}}applyExtraMarginBottom(t){if(t&&t.slot&&!t.isEmpty&&(t.creativeId||t.lineItemId||!t.isEmpty)){var o=t.slot.getSlotElementId();if(o){var s=document.getElementById(o);if(s)if((0,a.eq)(o)){var i=s?.closest(".js-zone-container");i.style.marginBottom="24px",e.cM("Applied extra margin to the bottom of "+o)}else e.cM("Not applying extra margin to the bottom of "+o+": shouldHaveReportButton = false");else e.cM("Not applying extra margin to the bottom of "+o+": resolved invalid adUnit element")}else e.cM("Not applying extra margin to the bottom of element: invalid adUnitElementId")}else e.cM("Not applying extra margin to the bottom of element: invalid SlotRenderEndedEvent")}load(o=(0,a.kG)()){const n=this.opt.tlb_position===t.Above?["dfp-mlb","dfp-smlb"]:["dfp-mlb","dfp-smlb","dfp-tlb"];if(!this.isGptReady())return e.cM("Initializing..."),this.initGpt(),void googletag.cmd.push(()=>this.load(o));this.opt.adReportEnabled?(e.cM("Ad reporting enabled"),this.adReports=new i.t(googletag,this)):(e.cM("Ad reporting not enabled"),this.handleSlotRenderedNoAdReport()),e.cM("Attempting to load ads into ids: ",o);const{eligible:r,ineligible:l}=this.classifyZoneIds(o);if(this.initDebugPanel(googletag,r.concat(l)),r.forEach(e=>(0,s.cf)(e)),l.forEach(s.wo),0===r.length)return void e.cM("Found no ad ids on page");e.cM("Eligible ids:",r),this.opt.abd&&this.appendAdblockDetector();var d=googletag.pubads().getSlots().filter(e=>o.indexOf(e.getSlotElementId())>=0);googletag.destroySlots(d),this.opt.sf&&(googletag.pubads().setForceSafeFrame(!0),googletag.pubads().setSafeFrameConfig({allowOverlayExpansion:!0,allowPushExpansion:!0,sandbox:!0})),e.cM("Targeting consent: Checking...");let c=!1,p=!1;void 0!==this.opt.targeting_consent&&(p=!0,e.cM("Targeting consent: Parameter set"),e.cM("Targeting consent: Consent given? ",this.opt.targeting_consent),c=this.opt.targeting_consent),void 0!==this.opt.personalization_consent&&(e.cM("Personalization consent: Parameter set"),e.cM("Personalization consent: Consent given? ",this.opt.personalization_consent),c=c&&this.opt.personalization_consent),c=c&&p,googletag.pubads().setRequestNonPersonalizedAds(c?0:1),c||googletag.pubads().setPrivacySettings({limitedAds:!0}),this.opt.ll||googletag.pubads().enableSingleRequest(),cam.sreEvent||(googletag.pubads().addEventListener("slotRenderEnded",e=>this.onSlotRendered(e)),cam.sreEvent=!0),this.setTargeting(googletag);var g=r.filter(e=>!this.opt.ll||n.indexOf(e.id)<0),h=r.filter(e=>!!this.opt.ll&&n.indexOf(e.id)>=0);e.cM("Up front ids:",g),e.cM("Lazy loaded ids:",h),g.forEach(t=>{e.cM(`Defining ad for element ${t.id}`),this.defineSlot(t.id,googletag),t.setAttribute("data-dfp-zone","true")}),googletag.enableServices(),g.forEach(t=>{e.cM(`Displaying ad for element ${t.id}`),googletag.cmd.push(()=>googletag.display(t.id))}),this.opt.ll&&(e.cM("Enabling lazy loading for GAM"),googletag.pubads().enableLazyLoad({fetchMarginPercent:0,renderMarginPercent:0}),e.cM("Setting up lazy loaded ad units"),h.forEach(t=>{e.cM(`Lazy loading - Defining Slot ${t.id}`),this.defineSlot(t.id,googletag)}),h.forEach(t=>{e.cM(`Lazy loading - Displaying ad for element ${t.id}`),googletag.cmd.push(()=>googletag.display(t.id))}))}setTargeting(t){let o=this.opt.targeting;if(!o)throw new Error("Targeting not defined");Object.keys(o).forEach(a=>{e.cM(`-> targeting - ${a}: ${o[a]}`),t.pubads().setTargeting(a,o[a])})}appendAdblockDetector(){const e=document.createElement("div");e.className="adsbox",e.id="clc-abd",e.style.position="absolute",e.style.pointerEvents="none",e.innerHTML="&nbsp;",document.body.appendChild(e)}onSlotRendered(o){try{const n=o.slot.getSlotElementId();let r=[];n||r.push("id=0");const l=document.getElementById(n);if(n&&!l&&r.push("el=0"),0!==r.length)return void this.stalled(r.join("&"));const{path:d,sizes:c,zone:p}=(0,a.Z7)(n);if(this.collapsed[p]&&o.isEmpty)return e.cM(`No line item for the element #${l.id}... collapsing.`),void(0,s.wo)(l);if(this.slotsRenderedEvents.push(o),o.lineItemId||o.creativeId||!o.isEmpty){e.cM(`Rendered ad for element #${l.id} [line item #${o.lineItemId}]`),e.cM(o);var i=l.parentElement;if(i.classList.contains("js-zone-container")){switch((0,s.cf)(i),n){case"dfp-tlb":this.opt.tlb_position===t.Above?i.classList.add("mb8"):i.classList.add("mt16");break;case"dfp-tag":i.classList.add("mb8");break;case"dfp-msb":i.classList.add("mt16");break;case"dfp-mlb":case"dfp-smlb":case"dfp-bmlb":i.classList.add("my8");break;case"dfp-isb":i.classList.add("mt24");break;case"dfp-m-aq":i.classList.add("my12"),i.classList.add("mx-auto")}(0,s.$Z)(i),(0,s.$Z)(l)}else e.cM(`No ad for element #${l.id}, collapsing`),e.cM(o),(0,s.wo)(l)}}catch(e){this.stalled("e=1")}}stalled(e){(new Image).src=`https://${this.clc_options.h}/stalled.gif?${e}`}defineSlot(t,o){"dfp-isb"===t&&(e.cM("-> targeting - Sidebar: Inline"),o.pubads().setTargeting("Sidebar",["Inline"])),"dfp-tsb"===t&&(e.cM("-> targeting - Sidebar: Right"),o.pubads().setTargeting("Sidebar",["Right"]));const{path:s,sizes:i,zone:n}=(0,a.Z7)(t);e.cM(`Defining slot for ${t}: ${s}, sizes: ${JSON.stringify(i)}`),o.defineSlot(s,i,t).addService(o.pubads())}importGptLibrary(){this.gptImported||(this.gptImported=!0,void 0===this.opt.targeting_consent||this.opt.targeting_consent?(0,s.Gx)("https://web.archive.org/web/20230306154331/https://securepubads.g.doubleclick.net/tag/js/gpt.js"):(0,s.Gx)("https://web.archive.org/web/20230306154331/https://pagead2.googlesyndication.com/tag/js/gpt.js"))}isGptReady(){return"undefined"!=typeof googletag&&!!googletag.apiReady}initGpt(){"undefined"==typeof googletag&&(window.googletag={cmd:(0,s.QZ)(()=>this.importGptLibrary())})}initDebugPanel(t,o){e.cM("initDebugPanel"),e.cM("Not showing debug panel")}},window.clcGamLoaderOptions&&(cam.init(),cam.load())})()})();</script> <footer id="footer" class="site-footer js-footer" role="contentinfo"> <div class="site-footer--container"> <div class="site-footer--logo"> <a href="https://web.archive.org/web/20230306154331/https://stackoverflow.com/" aria-label="Stack Overflow"><svg aria-hidden="true" class="native svg-icon iconLogoGlyphMd" width="32" height="37" viewbox="0 0 32 37"><path d="M26 33v-9h4v13H0V24h4v9h22Z" fill="#BCBBBB"/><path d="m21.5 0-2.7 2 9.9 13.3 2.7-2L21.5 0ZM26 18.4 13.3 7.8l2.1-2.5 12.7 10.6-2.1 2.5ZM9.1 15.2l15 7 1.4-3-15-7-1.4 3Zm14 10.79.68-2.95-16.1-3.35L7 23l16.1 2.99ZM23 30H7v-3h16v3Z" fill="#F48024"/></svg></a> </div> <nav class="site-footer--nav"> <div class="site-footer--col"> <h5 class="-title"><a href="https://web.archive.org/web/20230306154331/https://stackoverflow.com/" class="js-gps-track" data-gps-track="footer.click({ location: 5, link: 15})">Stack Overflow</a></h5> <ul class="-list js-primary-footer-links"> <li><a href="/web/20230306154331/https://stackoverflow.com/questions" class="js-gps-track -link" data-gps-track="footer.click({ location: 5, link: 16})">Questions</a></li> <li><a href="/web/20230306154331/https://stackoverflow.com/help" class="js-gps-track -link" data-gps-track="footer.click({ location: 5, link: 3 })">Help</a></li> </ul> </div> <div class="site-footer--col"> <h5 class="-title"><a href="https://web.archive.org/web/20230306154331/https://stackoverflow.co/" class="js-gps-track" data-gps-track="footer.click({ location: 5, link: 19 })">Products</a></h5> <ul class="-list"> <li><a href="https://web.archive.org/web/20230306154331/https://stackoverflow.co/teams" class="js-gps-track -link" data-ga="[&quot;teams traffic&quot;,&quot;footer - site nav&quot;,&quot;stackoverflow.com/teams&quot;,null,{&quot;dimension4&quot;:&quot;teams&quot;}]" data-gps-track="footer.click({ location: 5, link: 29 })">Teams</a></li> <li><a href="https://web.archive.org/web/20230306154331/https://stackoverflow.co/advertising" class="js-gps-track -link" data-gps-track="footer.click({ location: 5, link: 21 })">Advertising</a></li> <li><a href="https://web.archive.org/web/20230306154331/https://stackoverflow.co/collectives" class="js-gps-track -link" data-gps-track="footer.click({ location: 5, link: 40 })">Collectives</a></li> <li><a href="https://web.archive.org/web/20230306154331/https://stackoverflow.co/talent" class="js-gps-track -link" data-gps-track="footer.click({ location: 5, link: 20 })">Talent</a></li> </ul> </div> <div class="site-footer--col"> <h5 class="-title"><a class="js-gps-track" data-gps-track="footer.click({ location: 5, link: 1 })" href="https://web.archive.org/web/20230306154331/https://stackoverflow.co/">Company</a></h5> <ul class="-list"> <li><a class="js-gps-track -link" data-gps-track="footer.click({ location: 5, link: 1 })" href="https://web.archive.org/web/20230306154331/https://stackoverflow.co/">About</a></li> <li><a class="js-gps-track -link" data-gps-track="footer.click({ location: 5, link: 27 })" href="https://web.archive.org/web/20230306154331/https://stackoverflow.co/company/press">Press</a></li> <li><a class="js-gps-track -link" data-gps-track="footer.click({ location: 5, link: 9 })" href="https://web.archive.org/web/20230306154331/https://stackoverflow.co/company/work-here">Work Here</a></li> <li><a class="js-gps-track -link" data-gps-track="footer.click({ location: 5, link: 7 })" href="https://web.archive.org/web/20230306154331/https://stackoverflow.com/legal">Legal</a></li> <li><a class="js-gps-track -link" data-gps-track="footer.click({ location: 5, link: 8 })" href="https://web.archive.org/web/20230306154331/https://stackoverflow.com/legal/privacy-policy">Privacy Policy</a></li> <li><a class="js-gps-track -link" data-gps-track="footer.click({ location: 5, link: 37 })" href="https://web.archive.org/web/20230306154331/https://stackoverflow.com/legal/terms-of-service">Terms of Service</a></li> <li><a class="js-gps-track -link" data-gps-track="footer.click({ location: 5, link: 13 })" href="https://web.archive.org/web/20230306154331/https://stackoverflow.co/company/contact">Contact Us</a></li> <li class="" id="consent-footer-link"><a class="js-gps-track -link js-cookie-settings" data-gps-track="footer.click({ location: 5, link: 38 })" href="#" data-consent-popup-loader="footer">Cookie Settings</a></li> <li><a class="js-gps-track -link" data-gps-track="footer.click({ location: 5, link: 39 })" href="https://web.archive.org/web/20230306154331/https://stackoverflow.com/legal/cookie-policy">Cookie Policy</a></li> </ul> </div> <div class="site-footer--col site-footer--categories-nav"> <div> <h5 class="-title"><a href="https://web.archive.org/web/20230306154331/https://stackexchange.com/" data-gps-track="footer.click({ location: 5, link: 30 })">Stack Exchange Network</a></h5> <ul class="-list"> <li> <a href="https://web.archive.org/web/20230306154331/https://stackexchange.com/sites#technology" class="-link js-gps-track" data-gps-track="footer.click({ location: 5, link: 24 })"> Technology </a> </li> <li> <a href="https://web.archive.org/web/20230306154331/https://stackexchange.com/sites#culturerecreation" class="-link js-gps-track" data-gps-track="footer.click({ location: 5, link: 24 })"> Culture &amp; recreation </a> </li> <li> <a href="https://web.archive.org/web/20230306154331/https://stackexchange.com/sites#lifearts" class="-link js-gps-track" data-gps-track="footer.click({ location: 5, link: 24 })"> Life &amp; arts </a> </li> <li> <a href="https://web.archive.org/web/20230306154331/https://stackexchange.com/sites#science" class="-link js-gps-track" data-gps-track="footer.click({ location: 5, link: 24 })"> Science </a> </li> <li> <a href="https://web.archive.org/web/20230306154331/https://stackexchange.com/sites#professional" class="-link js-gps-track" data-gps-track="footer.click({ location: 5, link: 24 })"> Professional </a> </li> <li> <a href="https://web.archive.org/web/20230306154331/https://stackexchange.com/sites#business" class="-link js-gps-track" data-gps-track="footer.click({ location: 5, link: 24 })"> Business </a> </li> <li class="mt16 md:mt0"> <a href="https://web.archive.org/web/20230306154331/https://api.stackexchange.com/" class="-link js-gps-track" data-gps-track="footer.click({ location: 5, link: 24 })"> API </a> </li> <li> <a href="https://web.archive.org/web/20230306154331/https://data.stackexchange.com/" class="-link js-gps-track" data-gps-track="footer.click({ location: 5, link: 24 })"> Data </a> </li> </ul> </div> </div> </nav> <div class="site-footer--copyright fs-fine md:mt24"> <ul class="-list -social md:mb8"> <li><a class="js-gps-track -link" data-gps-track="footer.click({ location: 5, link:4 })" href="https://web.archive.org/web/20230306154331/https://stackoverflow.blog/?blb=1">Blog</a></li> <li><a href="https://web.archive.org/web/20230306154331/https://www.facebook.com/officialstackoverflow/" class="-link js-gps-track" data-gps-track="footer.click({ location: 5, link: 31 })">Facebook</a></li> <li><a href="https://web.archive.org/web/20230306154331/https://twitter.com/stackoverflow" class="-link js-gps-track" data-gps-track="footer.click({ location: 5, link: 32 })">Twitter</a></li> <li><a href="https://web.archive.org/web/20230306154331/https://linkedin.com/company/stack-overflow" class="-link js-gps-track" data-gps-track="footer.click({ location: 5, link: 33 })">LinkedIn</a></li> <li><a href="https://web.archive.org/web/20230306154331/https://www.instagram.com/thestackoverflow" class="-link js-gps-track" data-gps-track="footer.click({ location: 5, link: 36 })">Instagram</a></li> </ul> <p class="md:mb0"> Site design / logo &#169; 2023 Stack Exchange Inc; user contributions licensed under <span class="td-underline"><a href="https://web.archive.org/web/20230306154331/https://stackoverflow.com/help/licensing">CC BY-SA</a></span>. <span id="svnrev">rev&nbsp;2023.3.3.43278</span> </p> </div> </div> </footer> <!-- Google tag (gtag.js) --> <script async src="https://web.archive.org/web/20230306154331js_/https://www.googletagmanager.com/gtag/js?id=G-WCZ03SZFCQ"></script> <script> window.dataLayer = window.dataLayer || []; function gtag() { dataLayer.push(arguments); } </script> <script> StackExchange.ready(function() { var ga3Settings = { autoLink: ["stackoverflow.blog","info.stackoverflowsolutions.com","stackoverflowsolutions.com"], sendTitles: true, tracker: window.ga, trackingCodes: [ 'UA-108242619-1' ], checkDimension: 'dimension42' }; var customGA4Dimensions = {}; var ga4Settings = { tracker: gtag, trackingCodes: [ 'G-WCZ03SZFCQ' ], consentsToPerformanceCookies: "denied", consentsToTargetingCookies: "denied", eventParameters: customGA4Dimensions, checkForAdBlock: true }; StackExchange.ga.init({ GA3: ga3Settings, GA4: ga4Settings }); StackExchange.ga.setDimension('dimension2', '|python|'); StackExchange.ga.setDimension('dimension3', 'Questions/ListByTag'); StackExchange.ga.setDimension('dimension7', "1678117411.1514598598"); StackExchange.ga.trackPageView(); }); </script> <div class="ff-sans ps-fixed z-nav-fixed ws4 sm:w-auto p32 sm:p16 bg-black-750 fc-white bar-lg b16 l16 r16 js-consent-banner"> <svg aria-hidden="true" class="mln4 mb24 sm:d-none svg-spot spotCookieLg" style="color: var(--theme-button-filled-background-color)" width="96" height="96" viewbox="0 0 96 96"> <path d="M35 45.5a7.5 7.5 0 11-15 0 7.5 7.5 0 0115 0zM63.5 63a7.5 7.5 0 100-15 7.5 7.5 0 000 15zm-19 19a7.5 7.5 0 100-15 7.5 7.5 0 000 15z" opacity=".2"/> <path d="M56.99 2.53a23.1 23.1 0 0114.66 6.15h.01l.01.02c.57.55.61 1.27.5 1.74v.07a10.95 10.95 0 01-3.07 4.77 9 9 0 01-6.9 2.5 10.34 10.34 0 01-9.72-10.44v-.08a10 10 0 011.03-3.74l.01-.03.02-.02c.28-.5.82-.92 1.52-.95.63-.02 1.27-.02 1.93.01zm12.04 7.83a20.1 20.1 0 00-12.2-4.83l-.92-.03c-.23.6-.38 1.25-.43 1.94a7.34 7.34 0 006.95 7.34 6 6 0 004.64-1.7c.94-.88 1.6-1.9 1.96-2.72zm15.3 8.76a6.84 6.84 0 00-5.09-.24 7.9 7.9 0 00-3.28 2.05 1.8 1.8 0 00-.3 1.95l.02.02v.02a15.16 15.16 0 008.74 7.47c.64.23 1.32.08 1.8-.33a6.63 6.63 0 001.63-1.97l.01-.03.01-.03c1.67-3.5-.12-7.32-3.54-8.91zm-5.5 3.28c.36-.25.82-.5 1.35-.67.92-.3 1.92-.35 2.89.1 2.14 1 2.92 3.14 2.11 4.88-.12.21-.26.41-.43.6l-.26-.1a12.29 12.29 0 01-5.66-4.81zM32 24a2 2 0 11-4 0 2 2 0 014 0zm12 21a2 2 0 11-4 0 2 2 0 014 0zm36 4a2 2 0 11-4 0 2 2 0 014 0zm-7 21a2 2 0 11-4 0 2 2 0 014 0zM59 81a2 2 0 11-4 0 2 2 0 014 0zM22 63a2 2 0 11-4 0 2 2 0 014 0zm27 7a9 9 0 11-18 0 9 9 0 0118 0zm-3 0a6 6 0 10-12 0 6 6 0 0012 0zM33 41a9 9 0 11-18 0 9 9 0 0118 0zm-15 0a6 6 0 1012 0 6 6 0 00-12 0zm50 11a9 9 0 11-18 0 9 9 0 0118 0zm-3 0a6 6 0 10-12 0 6 6 0 0012 0zM44.08 4.24c.31.48.33 1.09.05 1.58a17.46 17.46 0 00-2.36 8.8c0 9.55 7.58 17.24 16.85 17.24 2.97 0 5.75-.78 8.16-2.15a1.5 1.5 0 012.1.66 12.08 12.08 0 0011 6.74 12.4 12.4 0 007.85-2.75 1.5 1.5 0 012.38.74A45.76 45.76 0 0192 48.16c0 24.77-19.67 44.9-44 44.9S4 72.93 4 48.16C4 25.23 20.84 6.28 42.64 3.58a1.5 1.5 0 011.44.66zM40.22 7C21.32 10.71 7 27.7 7 48.16c0 23.17 18.39 41.9 41 41.9s41-18.73 41-41.9c0-3.52-.42-6.93-1.22-10.2a15.5 15.5 0 01-7.9 2.15c-5.5 0-10.36-2.83-12.97-7.1a19.46 19.46 0 01-8.28 1.85c-11 0-19.86-9.1-19.86-20.24 0-2.7.52-5.26 1.45-7.62zM92 91a2 2 0 100-4 2 2 0 000 4zM7 8.5a2.5 2.5 0 11-5 0 2.5 2.5 0 015 0zM82.5 90a1.5 1.5 0 100-3 1.5 1.5 0 000 3zm9.5-7.5a1.5 1.5 0 11-3 0 1.5 1.5 0 013 0zM13.5 8a1.5 1.5 0 100-3 1.5 1.5 0 000 3zM80 14.5a1.5 1.5 0 11-3 0 1.5 1.5 0 013 0zM53.5 20a1.5 1.5 0 100-3 1.5 1.5 0 000 3z"/> </svg> <p class="fs-body2 fw-bold mb4"> Your privacy </p> <p class="mb16 s-anchors s-anchors__inherit s-anchors__underlined"> By clicking “Accept all cookies”, you agree Stack Exchange can store cookies on your device and disclose information in accordance with our <a href="https://web.archive.org/web/20230306154331/https://stackoverflow.com/legal/cookie-policy">Cookie Policy</a>. </p> <div class="d-flex gs8 sm:fd-column"> <button class="flex--item6 s-btn s-btn__primary js-accept-cookies js-consent-banner-hide"> Accept all cookies </button> <button class="flex--item6 s-btn s-btn__primary js-reject-cookies js-consent-banner-hide"> Necessary cookies only </button> </div> <div class="d-flex mt8 sm:fd-column"> <button class="flex--item12 s-btn s-btn__filled js-cookie-settings" data-consent-popup-loader="banner"> Customize settings </button> </div> </div> <div id="onetrust-consent-sdk" class="d-none"></div> <div id="onetrust-banner-sdk" data-controller="s-modal"></div> <div id="ot-pc-content" class="d-none"></div> <div id="onetrust-style" class="d-none">&nbsp;</div> <div class="d-none js-consent-banner-version" data-consent-banner-version="a1"></div> </body> </html> <!-- FILE ARCHIVED ON 15:43:31 Mar 06, 2023 AND RETRIEVED FROM THE INTERNET ARCHIVE ON 11:11:46 Dec 02, 2024. JAVASCRIPT APPENDED BY WAYBACK MACHINE, COPYRIGHT INTERNET ARCHIVE. ALL OTHER CONTENT MAY ALSO BE PROTECTED BY COPYRIGHT (17 U.S.C. SECTION 108(a)(3)). --> <!-- playback timings (ms): captures_list: 0.477 exclusion.robots: 0.03 exclusion.robots.policy: 0.021 esindex: 0.008 cdx.remote: 21.837 LoadShardBlock: 231.031 (3) PetaboxLoader3.datanode: 172.374 (4) PetaboxLoader3.resolve: 176.088 (2) load_resource: 201.445 -->

Pages: 1 2 3 4 5 6 7 8 9 10