{"id":71,"date":"2023-01-06T09:24:40","date_gmt":"2023-01-06T09:24:40","guid":{"rendered":"https:\/\/python.freelinuxtutorials.com\/?p=71"},"modified":"2023-01-06T09:24:40","modified_gmt":"2023-01-06T09:24:40","slug":"the-zen-of-python","status":"publish","type":"post","link":"https:\/\/python.freelinuxtutorials.com\/index.php\/2023\/01\/06\/the-zen-of-python\/","title":{"rendered":"The Zen of Python"},"content":{"rendered":"<p>What will happen if you open up a terminal, then type &#8220;import this&#8221;?<\/p>\n<p>In windows:<\/p>\n<blockquote><p>&gt;&gt;&gt; import this<\/p><\/blockquote>\n<p>C:\\Users\\darwin&gt;python<br \/>\nPython 3.9.12 (main, Apr 4 2022, 05:22:27) [MSC v.1916 64 bit (AMD64)] :: Anaconda, Inc. on win32<\/p>\n<p>Warning:<br \/>\nThis Python interpreter is in a conda environment, but the environment has<br \/>\nnot been activated. Libraries may fail to load. To activate this environment<br \/>\nplease see https:\/\/conda.io\/activation<\/p>\n<p>Type &#8220;help&#8221;, &#8220;copyright&#8221;, &#8220;credits&#8221; or &#8220;license&#8221; for more information.<br \/>\n&gt;&gt;&gt; import this<br \/>\nThe Zen of Python, by Tim Peters<\/p>\n<p>Beautiful is better than ugly.<br \/>\nExplicit is better than implicit.<br \/>\nSimple is better than complex.<br \/>\nComplex is better than complicated.<br \/>\nFlat is better than nested.<br \/>\nSparse is better than dense.<br \/>\nReadability counts.<br \/>\nSpecial cases aren&#8217;t special enough to break the rules.<br \/>\nAlthough practicality beats purity.<br \/>\nErrors should never pass silently.<br \/>\nUnless explicitly silenced.<br \/>\nIn the face of ambiguity, refuse the temptation to guess.<br \/>\nThere should be one&#8211; and preferably only one &#8211;obvious way to do it.<br \/>\nAlthough that way may not be obvious at first unless you&#8217;re Dutch.<br \/>\nNow is better than never.<br \/>\nAlthough never is often better than *right* now.<br \/>\nIf the implementation is hard to explain, it&#8217;s a bad idea.<br \/>\nIf the implementation is easy to explain, it may be a good idea.<br \/>\nNamespaces are one honking great idea &#8212; let&#8217;s do more of those!<br \/>\n&gt;&gt;&gt;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>What will happen if you open up a terminal, then type &#8220;import this&#8221;? In windows: &gt;&gt;&gt; import this C:\\Users\\darwin&gt;python Python 3.9.12 (main, Apr 4 2022, 05:22:27) [MSC v.1916 64 bit (AMD64)] :: Anaconda, Inc. on win32 Warning: This Python interpreter is in a conda environment, but the environment has not been activated. Libraries may fail&#8230;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"om_disable_all_campaigns":false,"footnotes":""},"categories":[1],"tags":[23],"class_list":["post-71","post","type-post","status-publish","format-standard","hentry","category-blog","tag-zen"],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/python.freelinuxtutorials.com\/index.php\/wp-json\/wp\/v2\/posts\/71","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/python.freelinuxtutorials.com\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/python.freelinuxtutorials.com\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/python.freelinuxtutorials.com\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/python.freelinuxtutorials.com\/index.php\/wp-json\/wp\/v2\/comments?post=71"}],"version-history":[{"count":1,"href":"https:\/\/python.freelinuxtutorials.com\/index.php\/wp-json\/wp\/v2\/posts\/71\/revisions"}],"predecessor-version":[{"id":72,"href":"https:\/\/python.freelinuxtutorials.com\/index.php\/wp-json\/wp\/v2\/posts\/71\/revisions\/72"}],"wp:attachment":[{"href":"https:\/\/python.freelinuxtutorials.com\/index.php\/wp-json\/wp\/v2\/media?parent=71"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/python.freelinuxtutorials.com\/index.php\/wp-json\/wp\/v2\/categories?post=71"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/python.freelinuxtutorials.com\/index.php\/wp-json\/wp\/v2\/tags?post=71"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}