{"id":21437,"date":"2023-06-20T09:00:00","date_gmt":"2023-06-20T07:00:00","guid":{"rendered":"https:\/\/www.codemotion.com\/magazine\/?p=21437"},"modified":"2024-03-26T16:23:35","modified_gmt":"2024-03-26T15:23:35","slug":"python","status":"publish","type":"post","link":"https:\/\/www.codemotion.com\/magazine\/languages\/python\/","title":{"rendered":"Python: The Versatile Programming Language That Captivates Everyone"},"content":{"rendered":"\n<p>Python is certainly one of the <strong>most widely used programming languages today<\/strong>. Thanks to its flexibility and a vast community of people, it is used in numerous companies worldwide for various purposes, allowing many developers to use it, despite different career paths.<\/p>\n\n\n\n<p>In this article, we will explore what type of language Python is, and why and how it differs from many other programming languages.<\/p>\n\n\n\n<p>We will then delve into the areas where Python is most commonly used, where to learn it, how to install it on our machines, and, finally, we will see how to write a simple program.<\/p>\n\n\n\t\t\t\t<div class=\"wp-block-uagb-table-of-contents uagb-toc__align-left uagb-toc__columns-1  uagb-block-846253d4      \"\n\t\t\t\t\tdata-scroll= \"1\"\n\t\t\t\t\tdata-offset= \"30\"\n\t\t\t\t\tstyle=\"\"\n\t\t\t\t>\n\t\t\t\t<div class=\"uagb-toc__wrap\">\n\t\t\t\t\t\t<div class=\"uagb-toc__title\">\n\t\t\t\t\t\t\tTable Of Contents\t\t\t\t\t\t<\/div>\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t<div class=\"uagb-toc__list-wrap \">\n\t\t\t\t\t\t<ol class=\"uagb-toc__list\"><li class=\"uagb-toc__list\"><a href=\"#what-kind-of-language-is-python-and-how-does-it-differ-from-others\" class=\"uagb-toc-link__trigger\">What kind of language is Python and how does it differ from others?<\/a><li class=\"uagb-toc__list\"><a href=\"#programming-in-python-what-can-i-do\" class=\"uagb-toc-link__trigger\">Programming in Python: What Can I Do?<\/a><li class=\"uagb-toc__list\"><a href=\"#how-and-where-to-learn-python-for-free-or-almost-free\" class=\"uagb-toc-link__trigger\">How and where to learn Python for free (or almost free)<\/a><li class=\"uagb-toc__list\"><a href=\"#how-to-install-python-on-your-pc\" class=\"uagb-toc-link__trigger\">How to install Python on your PC<\/a><li class=\"uagb-toc__list\"><a href=\"#how-to-install-python-on-windows-macos-and-linux\" class=\"uagb-toc-link__trigger\">How to install Python on Windows, macOS, and Linux<\/a><li class=\"uagb-toc__list\"><a href=\"#how-to-install-anaconda-on-windows-macos-and-linux\" class=\"uagb-toc-link__trigger\">How to install Anaconda on Windows, macOS, and Linux<\/a><li class=\"uagb-toc__list\"><a href=\"#how-to-write-a-program-in-python\" class=\"uagb-toc-link__trigger\">How to write a program in Python<\/a><li class=\"uagb-toc__list\"><a href=\"#start-programming-in-python\" class=\"uagb-toc-link__trigger\">Start programming in Python!<\/a><\/ol>\t\t\t\t\t<\/div>\n\t\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\n\n\n<h2 class=\"wp-block-heading\" id=\"h-what-kind-of-language-is-python-and-how-does-it-differ-from-others\">What kind of language is Python and how does it differ from others?<\/h2>\n\n\n\n<p>Python is a programming language that was first developed in 1989 by Dutch computer scientist <a href=\"https:\/\/en.wikipedia.org\/wiki\/Guido_van_Rossum\" target=\"_blank\" aria-label=\" (opens in a new tab)\" rel=\"noreferrer noopener\" class=\"ek-link\">Guido van Rossum<\/a>, who named it Python because he was a fan of the British TV series &#8220;Monthy Python&#8217;s Flying Circus&#8221;.<\/p>\n\n\n\n<p>As reported <a href=\"https:\/\/en.wikipedia.org\/wiki\/Guido_van_Rossum\" target=\"_blank\" aria-label=\" (opens in a new tab)\" rel=\"noreferrer noopener\" class=\"ek-link\">by Wikipedia<\/a>, &#8220;<em>In 1999, Van Rossum submitted a proposal to the Defense Advanced Research Projects Agency called Computer Programming for Everybody, in which he further defined his goals for Python:<\/em><\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>An easy and intuitive language just as powerful as major competitors<\/li>\n\n\n\n<li>Open source, so anyone can contribute to its development<\/li>\n\n\n\n<li>Code that is as understandable as plain English<\/li>\n\n\n\n<li>Suitability for everyday tasks, allowing for short development times<\/li>\n<\/ul>\n\n\n\n<p>In 2019, Python became <strong>the second most popular language on GitHub<\/strong>, the largest source code management website on the internet, second only to JavaScript.&#8221;<\/p>\n\n\n\n<p>The main difference between Python and other major similar programming languages is that <strong>Python is an interpreted language<\/strong>, while most similar languages are compiled.<\/p>\n\n\n\n<p>The difference between a compiled and interpreted language is that a compiled language is represented by a file already written in binary code, making it recognizable by a machine and, therefore, immediately executed.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<p><a href=\"https:\/\/www.codemotion.com\/magazine\/frontend\/frontend-trends-for-2024-css-revival-bff-ruling-languages-and-more\/\" target=\"_blank\" aria-label=\"Recommended article: Frontend Trends for 2024 (opens in a new tab)\" rel=\"noreferrer noopener\" class=\"ek-link\"><em><strong>Recommended article: Frontend Trends for 2024<\/strong><\/em><\/a><\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<p>In an interpreted language like Python, on the other hand, the program is represented by the source code and, each time it is launched, it is first translated and then compiled. While this represents the true strength of Python, <strong>making it a more user-friendly programming language<\/strong>, it is also somehow its Achilles&#8217; heel because it can decrease machines&#8217; performance, often making them too slow, and thus making Python unsuitable for applications where responsiveness is crucial.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<p><em><strong>Recommended read: <a href=\"https:\/\/www.codemotion.com\/magazine\/ai-ml\/big-data\/logging-in-python-a-broad-gentle-introduction\/\" target=\"_blank\" aria-label=\"Logging in Python, a gentle introduction (opens in a new tab)\" rel=\"noreferrer noopener\" class=\"ek-link\">Logging in Python, a gentle introduction<\/a>.<\/strong><\/em><\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<p>Lastly, Python is a high-level programming language because it provides a high level of abstraction, making it easier to write code compared to low-level programming languages.<\/p>\n\n\n\n<p>In other words, this means that developers can write Python code using concepts and constructs close to natural language, without worrying about low-level details, such as memory allocation or processor registers. This makes Python the perfect language for those who want to learn programming.<\/p>\n\n\n\n<p>An example? If I want to write a variable &#8220;age&#8221; to indicate my age, I can write:<\/p>\n\n\n<pre class=\"wp-block-code\"><span><code class=\"hljs\">age = 33\n<\/code><\/span><\/pre>\n\n\n<p>In other programming languages, especially compiled ones, it wouldn&#8217;t be the same.<\/p>\n\n\n\n<p>For example, to declare the same variable in C++, we would have to write it like this:<\/p>\n\n\n<pre class=\"wp-block-code\" aria-describedby=\"shcb-language-1\" data-shcb-language-name=\"PHP\" data-shcb-language-slug=\"php\"><span><code class=\"hljs language-php\"><span class=\"hljs-comment\">#include &lt;iostream&gt;<\/span>\n\nint main() {\n    int age = <span class=\"hljs-number\">33<\/span>;\n    <span class=\"hljs-comment\">\/\/ other commands or operations<\/span>\n    <span class=\"hljs-keyword\">return<\/span> <span class=\"hljs-number\">0<\/span>;\n}\n<\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-1\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">PHP<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">php<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n\n\n<p>And here we can immediately see the simplicity of Python compared to a compiled programming language.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Programming in Python: What Can I Do?<\/h2>\n\n\n\n<p>So, what exactly can we do with Python?<\/p>\n\n\n\n<p>The strength of Python relies on its flexibility and suitability for different types of problems and situations. In some cases, this flexibility is also its Achilles&#8217; heel, as we mentioned before. But on the other hand, as is evident, there is no optimal tool to solve every problem: there are specific tools for specific problems, although general-purpose tools can provide a good level of problem-solving.<\/p>\n\n\n\n<p>Anyway, let&#8217;s see the areas where Python is widely used with excellent results:<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li><strong>Automation<\/strong>. Thanks to its flexibility and a vast community of developers creating numerous libraries and providing support, <a href=\"https:\/\/www.codemotion.com\/magazine\/languages\/automate-everything-with-python\/\">Python is the perfect language for automation<\/a>. An example of automation? Let&#8217;s imagine having a folder with hundreds of files in different formats: images, PDF documents, Word documents, etc. With Python, we could write a program that reads the file extensions and puts them all in subfolders named &#8220;PDF,&#8221; &#8220;images,&#8221; etc.<\/li>\n\n\n\n<li><strong>Back-End development<\/strong>. Although Python has some rivals in the Back-End domain, it is still a widely used language by many companies worldwide to develop the Back-End part of many web applications. In fact, <a href=\"https:\/\/www.codemotion.com\/magazine\/languages\/top-python-frameworks\/\" class=\"ek-link\">Python has many frameworks<\/a> in this regard. The most commonly used ones are &#8220;Flask&#8221; and &#8220;Django.&#8221;<\/li>\n\n\n\n<li><strong>Data analysis, Machine Learning, and AI<\/strong>. Thanks to the multitude of libraries and frameworks, Python is the perfect language &#8211; and the most widely used one &#8211; for data analysis and Machine Learning. Libraries like `Pandas` are excellent for data analysis, and `scikit-learn` for Machine Learning. There are also various frameworks for Machine Learning and Deep Learning, such as `PyTorch` and `TensorFlow`.<\/li>\n<\/ol>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"576\" src=\"https:\/\/www.codemotion.com\/magazine\/wp-content\/uploads\/2022\/07\/Django1-1024x576.jpg\" alt=\"django python framework\" class=\"wp-image-18397\" srcset=\"https:\/\/www.codemotion.com\/magazine\/wp-content\/uploads\/2022\/07\/Django1-1024x576.jpg 1024w, https:\/\/www.codemotion.com\/magazine\/wp-content\/uploads\/2022\/07\/Django1-300x169.jpg 300w, https:\/\/www.codemotion.com\/magazine\/wp-content\/uploads\/2022\/07\/Django1-768x432.jpg 768w, https:\/\/www.codemotion.com\/magazine\/wp-content\/uploads\/2022\/07\/Django1-1536x864.jpg 1536w, https:\/\/www.codemotion.com\/magazine\/wp-content\/uploads\/2022\/07\/Django1-896x504.jpg 896w, https:\/\/www.codemotion.com\/magazine\/wp-content\/uploads\/2022\/07\/Django1-400x225.jpg 400w, https:\/\/www.codemotion.com\/magazine\/wp-content\/uploads\/2022\/07\/Django1.jpg 1919w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><figcaption class=\"wp-element-caption\">Django is one of Python&#8217;s most popular frameworks.<\/figcaption><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\">How and where to learn Python for free (or almost free)<\/h2>\n\n\n\n<p>Given its flexibility and relative ease of writing, Python is definitely the perfect language to start learning programming.<\/p>\n\n\n\n<p>Moreover, as it is used by many companies in various fields as we have seen, many people are willing to learn it. It can also be a good idea for a career change.<\/p>\n\n\n\n<p>Today, there are several online solutions to learn Python for free (or almost free). Here are some links:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>\u201c<a aria-label=\" (opens in a new tab)\" href=\"https:\/\/www.learnpython.org\/\" target=\"_blank\" rel=\"noreferrer noopener\" class=\"ek-link\">Learn Python<\/a>\u201d and \u201c<a aria-label=\" (opens in a new tab)\" href=\"https:\/\/www.tutorialspoint.com\/python\/index.htm\" target=\"_blank\" rel=\"noreferrer noopener\" class=\"ek-link\">tutorials point<\/a>\u201d are two websites where you can learn Python for free, and they also offer some learning paths to follow. If you prefer videos, instead, you can refer to the \u201cPython programming\u201d website.<\/li>\n<\/ul>\n\n\n\n<p>Of course, YouTube is also filled with free tutorials, but they often lack a structured learning path.<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>\u201c<a href=\"https:\/\/medium.com\/\" class=\"ek-link\">Medium<\/a>\u201d. Medium is a writing platform that has subscribing fee of $5\/month and offers a lot of Python tutorials for everyone (both beginners and advanced) and covers various topics (automation, Back-End, Machine Learning, etc.).<\/li>\n\n\n\n<li>\u201c<a href=\"https:\/\/www.udemy.com\/it\/\" target=\"_blank\" aria-label=\" (opens in a new tab)\" rel=\"noreferrer noopener\" class=\"ek-link\">Udemy<\/a>\u201d. Udemy is an excellent platform where you can find Python courses for all levels and various topics, for just a few tens of euros. It is great because it provides a structured path to follow from start to finish.<\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">How to install Python on your PC<\/h2>\n\n\n\n<p>There are several ways to install Python on a PC. Let&#8217;s see a couple of them.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">How to install Python on Windows, macOS, and Linux<\/h2>\n\n\n\n<p>To install Python on a Windows or macOS machine, simply visit <a href=\"https:\/\/www.python.org\/downloads\/\" target=\"_blank\" aria-label=\" (opens in a new tab)\" rel=\"noreferrer noopener\" class=\"ek-link\">this website<\/a>, download the latest version, and install it like a regular program.<\/p>\n\n\n\n<p>For Linux machines, we can either download the latest version from the above-mentioned website or use the terminal as follows:<\/p>\n\n\n<pre class=\"wp-block-code\"><span><code class=\"hljs\">$ sudo apt update\n$ sudo apt install python3<\/code><\/span><\/pre>\n\n\n<p>Now, the &#8220;issue&#8221; with this approach is that it will only install Python on our machines. Once we become familiar with the programming language, however, when we need to use <strong>libraries that are not included in the standard installation<\/strong>, we&#8217;ll have to install them one by one.<\/p>\n\n\n\n<p>To avoid this, one solution is to install Anaconda on our PC. This way, in addition to installing Python, <strong>we&#8217;ll also install all the commonly used libraries for data analysis and Machine Learning<\/strong>, as well as many libraries used in other domains.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">How to install Anaconda on Windows, macOS, and Linux<\/h2>\n\n\n\n<p>For all three operating systems, to install Anaconda we can visit <a href=\"https:\/\/www.anaconda.com\/download#downloads\" target=\"_blank\" aria-label=\" (opens in a new tab)\" rel=\"noreferrer noopener\" class=\"ek-link\">this link<\/a> and download the package for the latest version.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">How to write a program in Python<\/h2>\n\n\n\n<p>Earlier in this article, we wrote a Python program. Specifically, although the program doesn&#8217;t do anything special, it still does something important: it saves in memory that the value of the variable &#8220;age&#8221; is 33.<\/p>\n\n\n\n<p>Now, just for the pleasure of seeing the simplicity of Python, let&#8217;s write a small program.<\/p>\n\n\n\n<p>For example, let&#8217;s imagine we have a list of fruits. We want our program to consider all the fruits and print the phrase &#8220;I love &lt;fruit&gt;&#8221; with the name of each fruit.<\/p>\n\n\n\n<p>We can do it like this:<\/p>\n\n\n<pre class=\"wp-block-code\" aria-describedby=\"shcb-language-2\" data-shcb-language-name=\"PHP\" data-shcb-language-slug=\"php\"><span><code class=\"hljs language-php\"><span class=\"hljs-comment\"># Create a list of fruits<\/span>\nfruits = &#91;<span class=\"hljs-string\">\"banana\"<\/span>, <span class=\"hljs-string\">\"apple\"<\/span>, <span class=\"hljs-string\">\"pear\"<\/span>]\n\n<span class=\"hljs-comment\"># Iterate over the list<\/span>\n<span class=\"hljs-keyword\">for<\/span> fruit in fruits:\n    <span class=\"hljs-comment\"># Print phrase<\/span>\n    <span class=\"hljs-keyword\">print<\/span>(f<span class=\"hljs-string\">\"I love {fruit}\"<\/span>)\n\n&gt;&gt;&gt;\n\n   I love banana\n   I love apple\n   I love pear\n\n<\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-2\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">PHP<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">php<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n\n\n<p>So, in a very simple and intuitive way:<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>We created a list &#8220;fruits&#8221; that contains the names of some fruits.<\/li>\n\n\n\n<li>We created an auxiliary variable &#8220;fruit&#8221; that, through the &#8220;for loop&#8221;, iterates over all the elements of the &#8220;fruits&#8221; list.<\/li>\n\n\n\n<li>Finally, we printed our sentence for all the elements of the list using the `print()` command.<\/li>\n<\/ol>\n\n\n\n<h2 class=\"wp-block-heading\">Start programming in Python!<\/h2>\n\n\n\n<p>In this article, we have seen that Python is a programming language used in very diverse fields, ranging from Back End and <a href=\"https:\/\/www.codemotion.com\/magazine\/it\/backend-it\/microservizi-cosa-sono\/\" target=\"_blank\" aria-label=\"Python for Microservices (opens in a new tab)\" rel=\"noreferrer noopener\" class=\"ek-link\">Python for Microservices<\/a> to Machine Learning.<\/p>\n\n\n\n<p>Lastly, we have seen how, thanks to its simple syntax, we can write a program that is understandable even by non-experts in the development field.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Python is certainly one of the most widely used programming languages today. Thanks to its flexibility and a vast community of people, it is used in numerous companies worldwide for various purposes, allowing many developers to use it, despite different career paths. In this article, we will explore what type of language Python is, and&#8230; <a class=\"more-link\" href=\"https:\/\/www.codemotion.com\/magazine\/languages\/python\/\">Read more<\/a><\/p>\n","protected":false},"author":171,"featured_media":21430,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_editorskit_title_hidden":false,"_editorskit_reading_time":0,"_editorskit_is_block_options_detached":false,"_editorskit_block_options_position":"{}","_uag_custom_page_level_css":"","_genesis_hide_title":false,"_genesis_hide_breadcrumbs":false,"_genesis_hide_singular_image":false,"_genesis_hide_footer_widgets":false,"_genesis_custom_body_class":"","_genesis_custom_post_class":"","_genesis_layout":"","footnotes":""},"categories":[20],"tags":[10520,9907],"collections":[],"class_list":{"0":"post-21437","1":"post","2":"type-post","3":"status-publish","4":"format-standard","5":"has-post-thumbnail","7":"category-languages","8":"tag-django","9":"tag-frameworks","10":"entry"},"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v26.9 (Yoast SEO v26.9) - https:\/\/yoast.com\/product\/yoast-seo-premium-wordpress\/ -->\n<title>Programming in Python: Tips, Code Examples, and Key Resources!<\/title>\n<meta name=\"description\" content=\"Start programming in Python: discover what you can do with this versatile language, how and where to learn it, and more!\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.codemotion.com\/magazine\/languages\/python\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Python: The Versatile Programming Language That Captivates Everyone\" \/>\n<meta property=\"og:description\" content=\"Start programming in Python: discover what you can do with this versatile language, how and where to learn it, and more!\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.codemotion.com\/magazine\/languages\/python\/\" \/>\n<meta property=\"og:site_name\" content=\"Codemotion Magazine\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/Codemotion.Italy\/\" \/>\n<meta property=\"article:published_time\" content=\"2023-06-20T07:00:00+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2024-03-26T15:23:35+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.codemotion.com\/magazine\/wp-content\/uploads\/2023\/06\/iStock-1284202542-min.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"1365\" \/>\n\t<meta property=\"og:image:height\" content=\"768\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"Federico Trotta\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@CodemotionIT\" \/>\n<meta name=\"twitter:site\" content=\"@CodemotionIT\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Federico Trotta\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"7 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/www.codemotion.com\/magazine\/languages\/python\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/www.codemotion.com\/magazine\/languages\/python\/\"},\"author\":{\"name\":\"Federico Trotta\",\"@id\":\"https:\/\/www.codemotion.com\/magazine\/#\/schema\/person\/98d2abaf70e7d106abab1f38bf20f90d\"},\"headline\":\"Python: The Versatile Programming Language That Captivates Everyone\",\"datePublished\":\"2023-06-20T07:00:00+00:00\",\"dateModified\":\"2024-03-26T15:23:35+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/www.codemotion.com\/magazine\/languages\/python\/\"},\"wordCount\":1417,\"publisher\":{\"@id\":\"https:\/\/www.codemotion.com\/magazine\/#organization\"},\"image\":{\"@id\":\"https:\/\/www.codemotion.com\/magazine\/languages\/python\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/www.codemotion.com\/magazine\/wp-content\/uploads\/2023\/06\/iStock-1284202542-min.jpg\",\"keywords\":[\"Django\",\"Frameworks\"],\"articleSection\":[\"Languages and frameworks\"],\"inLanguage\":\"en-US\"},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.codemotion.com\/magazine\/languages\/python\/\",\"url\":\"https:\/\/www.codemotion.com\/magazine\/languages\/python\/\",\"name\":\"Programming in Python: Tips, Code Examples, and Key Resources!\",\"isPartOf\":{\"@id\":\"https:\/\/www.codemotion.com\/magazine\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/www.codemotion.com\/magazine\/languages\/python\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/www.codemotion.com\/magazine\/languages\/python\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/www.codemotion.com\/magazine\/wp-content\/uploads\/2023\/06\/iStock-1284202542-min.jpg\",\"datePublished\":\"2023-06-20T07:00:00+00:00\",\"dateModified\":\"2024-03-26T15:23:35+00:00\",\"description\":\"Start programming in Python: discover what you can do with this versatile language, how and where to learn it, and more!\",\"breadcrumb\":{\"@id\":\"https:\/\/www.codemotion.com\/magazine\/languages\/python\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.codemotion.com\/magazine\/languages\/python\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.codemotion.com\/magazine\/languages\/python\/#primaryimage\",\"url\":\"https:\/\/www.codemotion.com\/magazine\/wp-content\/uploads\/2023\/06\/iStock-1284202542-min.jpg\",\"contentUrl\":\"https:\/\/www.codemotion.com\/magazine\/wp-content\/uploads\/2023\/06\/iStock-1284202542-min.jpg\",\"width\":1365,\"height\":768,\"caption\":\"Python\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.codemotion.com\/magazine\/languages\/python\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/www.codemotion.com\/magazine\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Languages and frameworks\",\"item\":\"https:\/\/www.codemotion.com\/magazine\/languages\/\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"Python: The Versatile Programming Language That Captivates Everyone\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.codemotion.com\/magazine\/#website\",\"url\":\"https:\/\/www.codemotion.com\/magazine\/\",\"name\":\"Codemotion Magazine\",\"description\":\"We code the future. Together\",\"publisher\":{\"@id\":\"https:\/\/www.codemotion.com\/magazine\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.codemotion.com\/magazine\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/www.codemotion.com\/magazine\/#organization\",\"name\":\"Codemotion\",\"url\":\"https:\/\/www.codemotion.com\/magazine\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.codemotion.com\/magazine\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/www.codemotion.com\/magazine\/wp-content\/uploads\/2019\/11\/codemotionlogo.png\",\"contentUrl\":\"https:\/\/www.codemotion.com\/magazine\/wp-content\/uploads\/2019\/11\/codemotionlogo.png\",\"width\":225,\"height\":225,\"caption\":\"Codemotion\"},\"image\":{\"@id\":\"https:\/\/www.codemotion.com\/magazine\/#\/schema\/logo\/image\/\"},\"sameAs\":[\"https:\/\/www.facebook.com\/Codemotion.Italy\/\",\"https:\/\/x.com\/CodemotionIT\"]},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.codemotion.com\/magazine\/#\/schema\/person\/98d2abaf70e7d106abab1f38bf20f90d\",\"name\":\"Federico Trotta\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.codemotion.com\/magazine\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/69bc8655986054bfe43c7eaa7f00e2ea939b761bd924064ea9b5972568a01714?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/69bc8655986054bfe43c7eaa7f00e2ea939b761bd924064ea9b5972568a01714?s=96&d=mm&r=g\",\"caption\":\"Federico Trotta\"},\"description\":\"I have loved writing since I was a young boy in school, writing detective stories as class exams. Thanks to my curiosity, I discovered programming and AI. Having a burning passion for writing, I couldn't avoid starting to write about these topics, so I decided to change my career to become a Technical Writer. My purpose is to educate people on Python programming, Machine Learning, and Data Science, through writing.\",\"sameAs\":[\"https:\/\/federicotrotta.com\/\",\"https:\/\/www.linkedin.com\/in\/federico-trotta\/?originalSubdomain=it\"],\"url\":\"https:\/\/www.codemotion.com\/magazine\/author\/federico-trotta\/\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"Programming in Python: Tips, Code Examples, and Key Resources!","description":"Start programming in Python: discover what you can do with this versatile language, how and where to learn it, and more!","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.codemotion.com\/magazine\/languages\/python\/","og_locale":"en_US","og_type":"article","og_title":"Python: The Versatile Programming Language That Captivates Everyone","og_description":"Start programming in Python: discover what you can do with this versatile language, how and where to learn it, and more!","og_url":"https:\/\/www.codemotion.com\/magazine\/languages\/python\/","og_site_name":"Codemotion Magazine","article_publisher":"https:\/\/www.facebook.com\/Codemotion.Italy\/","article_published_time":"2023-06-20T07:00:00+00:00","article_modified_time":"2024-03-26T15:23:35+00:00","og_image":[{"width":1365,"height":768,"url":"https:\/\/www.codemotion.com\/magazine\/wp-content\/uploads\/2023\/06\/iStock-1284202542-min.jpg","type":"image\/jpeg"}],"author":"Federico Trotta","twitter_card":"summary_large_image","twitter_creator":"@CodemotionIT","twitter_site":"@CodemotionIT","twitter_misc":{"Written by":"Federico Trotta","Est. reading time":"7 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.codemotion.com\/magazine\/languages\/python\/#article","isPartOf":{"@id":"https:\/\/www.codemotion.com\/magazine\/languages\/python\/"},"author":{"name":"Federico Trotta","@id":"https:\/\/www.codemotion.com\/magazine\/#\/schema\/person\/98d2abaf70e7d106abab1f38bf20f90d"},"headline":"Python: The Versatile Programming Language That Captivates Everyone","datePublished":"2023-06-20T07:00:00+00:00","dateModified":"2024-03-26T15:23:35+00:00","mainEntityOfPage":{"@id":"https:\/\/www.codemotion.com\/magazine\/languages\/python\/"},"wordCount":1417,"publisher":{"@id":"https:\/\/www.codemotion.com\/magazine\/#organization"},"image":{"@id":"https:\/\/www.codemotion.com\/magazine\/languages\/python\/#primaryimage"},"thumbnailUrl":"https:\/\/www.codemotion.com\/magazine\/wp-content\/uploads\/2023\/06\/iStock-1284202542-min.jpg","keywords":["Django","Frameworks"],"articleSection":["Languages and frameworks"],"inLanguage":"en-US"},{"@type":"WebPage","@id":"https:\/\/www.codemotion.com\/magazine\/languages\/python\/","url":"https:\/\/www.codemotion.com\/magazine\/languages\/python\/","name":"Programming in Python: Tips, Code Examples, and Key Resources!","isPartOf":{"@id":"https:\/\/www.codemotion.com\/magazine\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.codemotion.com\/magazine\/languages\/python\/#primaryimage"},"image":{"@id":"https:\/\/www.codemotion.com\/magazine\/languages\/python\/#primaryimage"},"thumbnailUrl":"https:\/\/www.codemotion.com\/magazine\/wp-content\/uploads\/2023\/06\/iStock-1284202542-min.jpg","datePublished":"2023-06-20T07:00:00+00:00","dateModified":"2024-03-26T15:23:35+00:00","description":"Start programming in Python: discover what you can do with this versatile language, how and where to learn it, and more!","breadcrumb":{"@id":"https:\/\/www.codemotion.com\/magazine\/languages\/python\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.codemotion.com\/magazine\/languages\/python\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.codemotion.com\/magazine\/languages\/python\/#primaryimage","url":"https:\/\/www.codemotion.com\/magazine\/wp-content\/uploads\/2023\/06\/iStock-1284202542-min.jpg","contentUrl":"https:\/\/www.codemotion.com\/magazine\/wp-content\/uploads\/2023\/06\/iStock-1284202542-min.jpg","width":1365,"height":768,"caption":"Python"},{"@type":"BreadcrumbList","@id":"https:\/\/www.codemotion.com\/magazine\/languages\/python\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.codemotion.com\/magazine\/"},{"@type":"ListItem","position":2,"name":"Languages and frameworks","item":"https:\/\/www.codemotion.com\/magazine\/languages\/"},{"@type":"ListItem","position":3,"name":"Python: The Versatile Programming Language That Captivates Everyone"}]},{"@type":"WebSite","@id":"https:\/\/www.codemotion.com\/magazine\/#website","url":"https:\/\/www.codemotion.com\/magazine\/","name":"Codemotion Magazine","description":"We code the future. Together","publisher":{"@id":"https:\/\/www.codemotion.com\/magazine\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.codemotion.com\/magazine\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/www.codemotion.com\/magazine\/#organization","name":"Codemotion","url":"https:\/\/www.codemotion.com\/magazine\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.codemotion.com\/magazine\/#\/schema\/logo\/image\/","url":"https:\/\/www.codemotion.com\/magazine\/wp-content\/uploads\/2019\/11\/codemotionlogo.png","contentUrl":"https:\/\/www.codemotion.com\/magazine\/wp-content\/uploads\/2019\/11\/codemotionlogo.png","width":225,"height":225,"caption":"Codemotion"},"image":{"@id":"https:\/\/www.codemotion.com\/magazine\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/Codemotion.Italy\/","https:\/\/x.com\/CodemotionIT"]},{"@type":"Person","@id":"https:\/\/www.codemotion.com\/magazine\/#\/schema\/person\/98d2abaf70e7d106abab1f38bf20f90d","name":"Federico Trotta","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.codemotion.com\/magazine\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/69bc8655986054bfe43c7eaa7f00e2ea939b761bd924064ea9b5972568a01714?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/69bc8655986054bfe43c7eaa7f00e2ea939b761bd924064ea9b5972568a01714?s=96&d=mm&r=g","caption":"Federico Trotta"},"description":"I have loved writing since I was a young boy in school, writing detective stories as class exams. Thanks to my curiosity, I discovered programming and AI. Having a burning passion for writing, I couldn't avoid starting to write about these topics, so I decided to change my career to become a Technical Writer. My purpose is to educate people on Python programming, Machine Learning, and Data Science, through writing.","sameAs":["https:\/\/federicotrotta.com\/","https:\/\/www.linkedin.com\/in\/federico-trotta\/?originalSubdomain=it"],"url":"https:\/\/www.codemotion.com\/magazine\/author\/federico-trotta\/"}]}},"featured_image_src":"https:\/\/www.codemotion.com\/magazine\/wp-content\/uploads\/2023\/06\/iStock-1284202542-min-600x400.jpg","featured_image_src_square":"https:\/\/www.codemotion.com\/magazine\/wp-content\/uploads\/2023\/06\/iStock-1284202542-min-600x600.jpg","author_info":{"display_name":"Federico Trotta","author_link":"https:\/\/www.codemotion.com\/magazine\/author\/federico-trotta\/"},"uagb_featured_image_src":{"full":["https:\/\/www.codemotion.com\/magazine\/wp-content\/uploads\/2023\/06\/iStock-1284202542-min.jpg",1365,768,false],"thumbnail":["https:\/\/www.codemotion.com\/magazine\/wp-content\/uploads\/2023\/06\/iStock-1284202542-min-150x150.jpg",150,150,true],"medium":["https:\/\/www.codemotion.com\/magazine\/wp-content\/uploads\/2023\/06\/iStock-1284202542-min-300x169.jpg",300,169,true],"medium_large":["https:\/\/www.codemotion.com\/magazine\/wp-content\/uploads\/2023\/06\/iStock-1284202542-min-768x432.jpg",768,432,true],"large":["https:\/\/www.codemotion.com\/magazine\/wp-content\/uploads\/2023\/06\/iStock-1284202542-min-1024x576.jpg",1024,576,true],"1536x1536":["https:\/\/www.codemotion.com\/magazine\/wp-content\/uploads\/2023\/06\/iStock-1284202542-min.jpg",1365,768,false],"2048x2048":["https:\/\/www.codemotion.com\/magazine\/wp-content\/uploads\/2023\/06\/iStock-1284202542-min.jpg",1365,768,false],"small-home-featured":["https:\/\/www.codemotion.com\/magazine\/wp-content\/uploads\/2023\/06\/iStock-1284202542-min.jpg",100,56,false],"sidebar-featured":["https:\/\/www.codemotion.com\/magazine\/wp-content\/uploads\/2023\/06\/iStock-1284202542-min-180x128.jpg",180,128,true],"genesis-singular-images":["https:\/\/www.codemotion.com\/magazine\/wp-content\/uploads\/2023\/06\/iStock-1284202542-min-896x504.jpg",896,504,true],"archive-featured":["https:\/\/www.codemotion.com\/magazine\/wp-content\/uploads\/2023\/06\/iStock-1284202542-min-400x225.jpg",400,225,true],"gb-block-post-grid-landscape":["https:\/\/www.codemotion.com\/magazine\/wp-content\/uploads\/2023\/06\/iStock-1284202542-min-600x400.jpg",600,400,true],"gb-block-post-grid-square":["https:\/\/www.codemotion.com\/magazine\/wp-content\/uploads\/2023\/06\/iStock-1284202542-min-600x600.jpg",600,600,true]},"uagb_author_info":{"display_name":"Federico Trotta","author_link":"https:\/\/www.codemotion.com\/magazine\/author\/federico-trotta\/"},"uagb_comment_info":0,"uagb_excerpt":"Python is certainly one of the most widely used programming languages today. Thanks to its flexibility and a vast community of people, it is used in numerous companies worldwide for various purposes, allowing many developers to use it, despite different career paths. In this article, we will explore what type of language Python is, and&#8230;&hellip;","lang":"en","_links":{"self":[{"href":"https:\/\/www.codemotion.com\/magazine\/wp-json\/wp\/v2\/posts\/21437","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.codemotion.com\/magazine\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.codemotion.com\/magazine\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.codemotion.com\/magazine\/wp-json\/wp\/v2\/users\/171"}],"replies":[{"embeddable":true,"href":"https:\/\/www.codemotion.com\/magazine\/wp-json\/wp\/v2\/comments?post=21437"}],"version-history":[{"count":3,"href":"https:\/\/www.codemotion.com\/magazine\/wp-json\/wp\/v2\/posts\/21437\/revisions"}],"predecessor-version":[{"id":26770,"href":"https:\/\/www.codemotion.com\/magazine\/wp-json\/wp\/v2\/posts\/21437\/revisions\/26770"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.codemotion.com\/magazine\/wp-json\/wp\/v2\/media\/21430"}],"wp:attachment":[{"href":"https:\/\/www.codemotion.com\/magazine\/wp-json\/wp\/v2\/media?parent=21437"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.codemotion.com\/magazine\/wp-json\/wp\/v2\/categories?post=21437"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.codemotion.com\/magazine\/wp-json\/wp\/v2\/tags?post=21437"},{"taxonomy":"collections","embeddable":true,"href":"https:\/\/www.codemotion.com\/magazine\/wp-json\/wp\/v2\/collections?post=21437"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}