<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Kouti Divine</title>
    <description>The latest articles on DEV Community by Kouti Divine (@divine016).</description>
    <link>https://dev.to/divine016</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F812601%2Ffda35018-4ed5-4182-bc72-be9ca0568368.jpg</url>
      <title>DEV Community: Kouti Divine</title>
      <link>https://dev.to/divine016</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/divine016"/>
    <language>en</language>
    <item>
      <title>What happens when you type google.com in your browser and press Enter…</title>
      <dc:creator>Kouti Divine</dc:creator>
      <pubDate>Thu, 17 Aug 2023 14:13:47 +0000</pubDate>
      <link>https://dev.to/divine016/what-happens-when-you-type-googlecom-in-your-browser-and-press-enter-45fa</link>
      <guid>https://dev.to/divine016/what-happens-when-you-type-googlecom-in-your-browser-and-press-enter-45fa</guid>
      <description>&lt;h4&gt;
  
  
  ABSTRACT
&lt;/h4&gt;

&lt;p&gt;Have you ever tried using a new pc and you want to do a search on a topic and you are not satisfied with the results you get on the browser available. Then you decide you would use the browser available to access google.com? &lt;br&gt;
Yeah that has  happened to me too!!&lt;/p&gt;

&lt;p&gt;Have you ever wondered what happens in the background when you type google.com on Microsoft edge? Or what happens when you enter a URL on the web browser or search engine and get your results?&lt;/p&gt;

&lt;p&gt;One thing we know for sure is that when we type google.com we wait for a few seconds then we get our google page displayed on the screen for use. But in reality there are a lot of processes happening in the background so that we could get our page.&lt;/p&gt;

&lt;p&gt;In this article we would talk about what really happens in the background and all the different processes involved such as  DNS, TCP/IP HTTPS and many more.&lt;/p&gt;

&lt;h2&gt;
  
  
  When the google.com is typed,
&lt;/h2&gt;

&lt;h3&gt;
  
  
  The different caches are first checked.
&lt;/h3&gt;

&lt;p&gt;The bowser looks at different cache such as the &lt;br&gt;
browser cache, operating system cache, router cache and ISP(internet service provider) cache to see if we have the IP address of that domain name stored in it. &lt;br&gt;
If the IP address is found then the browser uses the IP address found  in the cache to establish a connection with the server.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Cache&lt;/strong&gt;: it refers to a temporal storage of data. Taking an example of the browser cache, IP addresses are temporarily stored in it such that if a research is made and the IP address of the domain name is found in the browser cache then a connection is made with the IP found in the cache and the server speeding up the process required to get the results since the browser does not have to send a request to the DNS server.&lt;/p&gt;

&lt;h3&gt;
  
  
  DNS QUERY
&lt;/h3&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--5WDoZjiS--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/carbi0qwji07lg6ybwt2.PNG" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--5WDoZjiS--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/carbi0qwji07lg6ybwt2.PNG" alt="Image demostrating how dns query works from tecttarget website" width="800" height="315"&gt;&lt;/a&gt;&lt;br&gt;
If the IP address is not found in the cache then the Internet service provider sends a query to the DNS server so that it resolves the domain name into an IP address. &lt;br&gt;
&lt;strong&gt;DNS&lt;/strong&gt;: Domain name system for short DNS is a server that contains ip addresses for domain names. When a domain name is typed in the browser the DNS translates it into an IP address which can be used to gain access to websites and other  materials on the internet&lt;/p&gt;

&lt;h3&gt;
  
  
  TCP/IP CONNECTION
&lt;/h3&gt;

&lt;p&gt;Once the IP address of google.com  is obtained a connection is made between the browser and the server which contains the IP of google.com. This connection is possible through the TCP/IP known as transmission control protocol/ internet protocol which is a protocol that governs the way information is being shared over the internet. And this process is known as TCP 3 way handshake.&lt;/p&gt;

&lt;p&gt;The &lt;strong&gt;TCP/IP&lt;/strong&gt; is one type of protocol as there exist many types of protocols such as UTP and each protocol is used for different reasons.&lt;br&gt;
Once the connection is made the browser and server can communicate together.&lt;/p&gt;

&lt;h3&gt;
  
  
  FIREWALL
&lt;/h3&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--RDjfo19G--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/atttlkjl5ffihg093xfg.PNG" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--RDjfo19G--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/atttlkjl5ffihg093xfg.PNG" alt="image demonstrating a firewall from simplilearn" width="626" height="240"&gt;&lt;/a&gt;&lt;br&gt;
Most computers using the windows operating system have a built-in firewall. A &lt;strong&gt;firewall&lt;/strong&gt; is a security system that is there to control and monitor incoming and outgoing network traffic on a device based on its configuration.&lt;br&gt;
If the computer has a firewall it would check to see if the connection is secure or not. If the connection is secure then the browser and the server can share information if not the firewall would block the browser from accessing information coming from the server.&lt;br&gt;
Also if the server is behind a firewall it would check to see if the connection is secure if not it blocks requests coming from that computer.&lt;/p&gt;

&lt;h3&gt;
  
  
  HTTPS/SSL
&lt;/h3&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--XgcReh-F--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/9tpt34bd4xr2j99eb362.PNG" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--XgcReh-F--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/9tpt34bd4xr2j99eb362.PNG" alt="Image demonstating an http request from community.safe.com" width="800" height="219"&gt;&lt;/a&gt;&lt;br&gt;
Once the connection between the browser and server is established, the browser needs to get data from the server. This is done by using either Hypertext transfer protocol or Hypertext transfer protocol secure for short http or https respectively. Http is a protocol that is used to share data between browsers and servers. The difference between Http and Https is, https has a layer of security that the information being shared over https is being encrypted while that of http is not encrypted. &lt;/p&gt;

&lt;p&gt;We would consider using &lt;strong&gt;Https&lt;/strong&gt; to get the data from the browser. The browser sends a HTTP request to the server using an encryption protocol which is secure socket layer (SSL) now known as transport layer security (TLS) (the browser says hey server I would like to get google.com) and the server processes the REQUEST and then sends a reply(yes you can have the page). This reply could include files that include HTML, CSS, JavaScript, images, videos and other media files.&lt;/p&gt;

&lt;h3&gt;
  
  
  LOAD BALANCING
&lt;/h3&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--lSFNZzwN--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ktpx4bkr238bbl37fv4e.PNG" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--lSFNZzwN--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ktpx4bkr238bbl37fv4e.PNG" alt="image demonstrating load balancing from nginx.com" width="665" height="332"&gt;&lt;/a&gt;&lt;br&gt;
From &lt;a href="https://www.nginx.com/resources/glossary/load-balancing/"&gt;nginx&lt;/a&gt; website, &lt;br&gt;
&lt;em&gt;Load balancing refers to efficiently distributing incoming network traffic across a group of backend servers, also known as a server farm or server pool.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;When  you type google.com in the browser the load balancer takes this request and forwards the request to a server which  would reply to this request in a fast and reliable manner. Once the server has a reply it would forward this reply to the load balancer which would then forward the reply to your browser. As mentioned above this reply may include files, videos and other media files.&lt;br&gt;
If you want to know more about load balancing visit this &lt;a href="https://www.nginx.com/resources/glossary/load-balancing/"&gt;website&lt;/a&gt;site()&lt;/p&gt;

&lt;h3&gt;
  
  
  Web server
&lt;/h3&gt;

&lt;p&gt;The &lt;strong&gt;webserver&lt;/strong&gt; is responsible for accepting and answering  users' demand for static content such as HTML, CSS, and JavaScript files. That is content that does not require interaction. &lt;/p&gt;

&lt;h3&gt;
  
  
  Page rendering and display
&lt;/h3&gt;

&lt;p&gt;The web server has given the response to the browser now we need to be able to see this response on our screens. &lt;br&gt;
In this case the response we have is google.com. This response contains html, CSS and javascript code. The html code is parsed and the CSS is used to style the html. The javascript code is then executed by the browser and all of this is displayed on our screens. Making us to see the google home page when we type google.com on our browsers.&lt;br&gt;
&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--wen4iS28--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/y3evhzn1syv9lkw1od4r.PNG" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--wen4iS28--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/y3evhzn1syv9lkw1od4r.PNG" alt="google landing page" width="800" height="417"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;In some cases our request would need to involve the Application and database servers&lt;/p&gt;

&lt;h3&gt;
  
  
  Application server and database server.
&lt;/h3&gt;

&lt;p&gt;The &lt;strong&gt;Application&lt;/strong&gt; server is responsible for providing dynamic content to users. For example when you login or provide some information to a website and there is information provided to you based on your location or your preferences or based on the information you provided, that's the application server at work. For short the application server permits users to interact with their content.&lt;br&gt;
&lt;strong&gt;Databases&lt;/strong&gt; are like storage. Let's take a database to be like a well organised store where we store our goods in an orderly manner.&lt;br&gt;
Databases are used to store all types of information depending on what we are creating the database for. There are different types of database but this is not what we are talking about right?&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Now how do the webserver, application server and database server work together to provide us with information?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Once the web server sends the information to the browser and the information is displayed on the screen if the user needs to interact with the website or the page, maybe by submitting a form, then the web server would send a request to the application server. &lt;br&gt;
If the request needs information from the database then the application server would send a request to the database server so as to get the information required from its database. &lt;br&gt;
The database server would then forward the response acquired to the application server which would then process this response then display the response on your screen.&lt;/p&gt;

&lt;h3&gt;
  
  
  Conclusion:
&lt;/h3&gt;

&lt;p&gt;I hope after reading this article you have been able to understand what happens in the background when you enter a &lt;strong&gt;google.com&lt;/strong&gt; or a URL in your browser. Thank you for reading.&lt;br&gt;
If you have any question you can reach out to me on &lt;a href="https://twitter.com/kouts_CQ"&gt; twitter&lt;/a&gt;&lt;br&gt;
Or send me an email on &lt;a href="mailto:koutidivine@gmail.com"&gt;koutidivine@gmail.com&lt;/a&gt; .&lt;/p&gt;

</description>
      <category>javascript</category>
      <category>programming</category>
      <category>google</category>
      <category>writing</category>
    </item>
    <item>
      <title>A Closer Look at Recursion: Examples in Popular Programming Languages</title>
      <dc:creator>Kouti Divine</dc:creator>
      <pubDate>Fri, 17 Mar 2023 13:22:47 +0000</pubDate>
      <link>https://dev.to/divine016/a-closer-look-at-recursion-examples-in-popular-programming-languages-5am9</link>
      <guid>https://dev.to/divine016/a-closer-look-at-recursion-examples-in-popular-programming-languages-5am9</guid>
      <description>&lt;p&gt;There are different programming languages like Python, Java, C, C++, Dart, Typescript, Javascript and all these Programming Languages have different ways of implementing recursion. &lt;/p&gt;

&lt;p&gt;Recursion is a concept in programming that helps us resolve certain tasks or problems. It  can be used to replace loops such as the for loop. In this article we are going to  be talking about recursion and how we can implement it in different programming languages.&lt;/p&gt;

&lt;h2&gt;
  
  
  Introduction to recursion.
&lt;/h2&gt;

&lt;p&gt;Let us consider a gift box bearing other gift boxes. If we open  the first box we see another box in it. This continues until we reach the box that contains our gift. But if we want to close back all the boxes then we would have to start closing from the smallest box right up to the largest box which is the first box we opened. &lt;/p&gt;

&lt;p&gt;In the image below we consider that the red box at the end is our gift and we need to open up 6 boxes for us to get our gift.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F5nuhh9y8bpronsja9fyi.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F5nuhh9y8bpronsja9fyi.png" alt="recursion image"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  What is recursion.
&lt;/h3&gt;

&lt;p&gt;From the above explanation we can say recursion  refers to solving a big problem by breaking it down into smaller chunks  until it  reaches the last level. Then starts solving each chunk starting with the “base case” bit by bit until it reaches the largest chunk.&lt;/p&gt;

&lt;p&gt;Using technical terms, we would say recursion is a concept in programming that allows us to define a function, and call that function in its function definition.&lt;/p&gt;

&lt;h2&gt;
  
  
  How it works.
&lt;/h2&gt;

&lt;p&gt;When we define a recursive function, we need to define a condition  that would help us break the calling of the function and start solving each chunk till we get the final answer. This condition is known as the base case  or &lt;strong&gt;base condition&lt;/strong&gt;. &lt;/p&gt;

&lt;p&gt;Just like in our example of the gift box, we need to reach the red box before we can start closing it up all over again. &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;For example&lt;/strong&gt; let write a function  to add  &lt;strong&gt;n&lt;/strong&gt;  numbers in an &lt;strong&gt;array&lt;/strong&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Algorithm
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;First we need to look for the &lt;strong&gt;base case&lt;/strong&gt;. &lt;/li&gt;
&lt;li&gt;Secondly we need to access each element in that array and add 
them together so that at the end we get the sum of all element 
in the array.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F6yuq8vgvo11fmo6a5uyt.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F6yuq8vgvo11fmo6a5uyt.png" alt="javascript code to add numbers in an array"&gt;&lt;/a&gt;&lt;br&gt;
&lt;strong&gt;n &amp;lt;= 0&lt;/strong&gt; //&lt;em&gt;this condition in the if statement refers to base condition&lt;/em&gt;. &lt;br&gt;
Each time the code would run, it would check if it fulfils the condition if not it does the else statement until the base condition is fulfilled.&lt;/p&gt;

&lt;h3&gt;
  
  
  How the code runs
&lt;/h3&gt;

&lt;p&gt;Let's consider the arguments passed in the function  are ([1, 2, 3,4], 3)&lt;br&gt;
&lt;strong&gt;First time:&lt;/strong&gt;&lt;br&gt;
    Is n &amp;lt;= 0? No so it does the else statement&lt;br&gt;
    Which is  addnums([1, 2, 3,4], 2) + arr[2]&lt;br&gt;
&lt;strong&gt;Second time:&lt;/strong&gt;&lt;br&gt;
    Is  n &amp;lt;= 0? No so it does the else statement&lt;br&gt;
Which is  addnums([1, 2, 3,4], 1) + arr[1]&lt;br&gt;
&lt;strong&gt;Third time&lt;/strong&gt;:&lt;br&gt;
    Is  n &amp;lt;= 0? No so it does the else statement&lt;br&gt;
Which is  addnums([1, 2, 3,4], 0) + arr[0]&lt;br&gt;
Since n = 0 then it returns 0&lt;/p&gt;

&lt;p&gt;Then it starts going upward&lt;/p&gt;

&lt;p&gt;arr[0] = 1&lt;br&gt;
arr[1] = 2&lt;br&gt;
arr [2] = 3&lt;br&gt;
So it takes 1+2+3 and gives 6&lt;/p&gt;

&lt;h2&gt;
  
  
  Some examples on recursion
&lt;/h2&gt;

&lt;p&gt;Examples gotten from &lt;a href="https://www.freecodecamp.org/learn/javascript-algorithms-and-data-structures" rel="noopener noreferrer"&gt;freeCodeCamp&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  1. Writing a function that uses recursion to create a countdown:
&lt;/h3&gt;

&lt;h4&gt;
  
  
  How to solve this problem
&lt;/h4&gt;

&lt;p&gt;.&lt;br&gt;
The  code would define a function called &lt;strong&gt;countDown&lt;/strong&gt;  in javascript &lt;strong&gt;count_down&lt;/strong&gt; in pyhton which takes one argument called  &lt;strong&gt;n&lt;/strong&gt;  and if &lt;strong&gt;n&lt;/strong&gt;  is lesser than 1 then it returns an empty array &lt;br&gt;
If not it cals defines a variable called &lt;em&gt;count_array(or countArray)&lt;/em&gt; and give it a value of &lt;em&gt;count_down(n - 1)( or countDown(n-1))&lt;/em&gt; and for each value stored in &lt;em&gt;count_array(countArray)&lt;/em&gt; it includes it in the array &lt;em&gt;count_array(or countArray)&lt;/em&gt; and returns &lt;em&gt;count_array&lt;/em&gt; as the final array.&lt;/p&gt;

&lt;h4&gt;
  
  
  Implementation in python
&lt;/h4&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fwnf0bfq2457o6fy6j4ng.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fwnf0bfq2457o6fy6j4ng.png" alt="countdown code in python"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The output for this pythont code  gives 5, 4, 3, 2, 1&lt;/p&gt;

&lt;h4&gt;
  
  
  Implementation in Javascript
&lt;/h4&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fpu9m6x7uctkxzhe467fh.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fpu9m6x7uctkxzhe467fh.png" alt="countdown code in javascript"&gt;&lt;/a&gt;&lt;br&gt;
The output for this Javascript code  gives 5, 4, 3, 2, 1.&lt;/p&gt;

&lt;h3&gt;
  
  
  2. Use recursion to create a range of numbers:
&lt;/h3&gt;

&lt;h4&gt;
  
  
  How to solve this problem:
&lt;/h4&gt;

&lt;p&gt;The  code would define a function called &lt;strong&gt;range_of_numbers&lt;/strong&gt;  in python, &lt;strong&gt;rangeOfNumbers&lt;/strong&gt; in javascript  which takes two argument called  &lt;strong&gt;startNum&lt;/strong&gt; and  &lt;strong&gt;endNum&lt;/strong&gt; in javascript , &lt;strong&gt;start_num&lt;/strong&gt; and &lt;strong&gt;end_num&lt;/strong&gt; in python.&lt;br&gt;
If startNum is equal to endNum then it should return the first argument which is addNum.&lt;br&gt;
Else it assigns the value  rangeOfNumbers(startNum, endNum -1) to the variable &lt;strong&gt;down&lt;/strong&gt; and returns the variable &lt;strong&gt;down&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Implementation in python&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fnszslj71atq6xlqoyiqh.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fnszslj71atq6xlqoyiqh.png" alt="python code for range of numbers"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The output for this python code gives [3, 4, 5, 6, 7] for the first case and  [3] for the second case.&lt;/p&gt;

&lt;p&gt;Implementation in Javascript&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fu0ed2fe80qqitbjpo0b0.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fu0ed2fe80qqitbjpo0b0.png" alt="range-of-numbers code in javascript"&gt;&lt;/a&gt;&lt;br&gt;
The output for this javascript code  gives [3, 4, 5, 6, 7] for the first case and  [3] for the second case.&lt;/p&gt;

&lt;p&gt;Recursion can be used when we want to break down complex problems into smaller ones, replace the use of loops and  also to make our code look cleaner. &lt;br&gt;
But it should not be implemented in all cases since it is costly as it reserves a space in memory for each recursive call that is being made.&lt;br&gt;
From the above article we have seen examples on how to use and implement recursion and I hope that you have  understood what recursion is all about.&lt;br&gt;
Thank you for reading.&lt;br&gt;
you could connect with me on &lt;a href="https://twitter.com/kouts_CQ" rel="noopener noreferrer"&gt;twitter&lt;/a&gt;&lt;/p&gt;

</description>
      <category>javascript</category>
      <category>python</category>
      <category>programming</category>
      <category>tech</category>
    </item>
    <item>
      <title>##API 101 WITH POSTMAN API</title>
      <dc:creator>Kouti Divine</dc:creator>
      <pubDate>Tue, 22 Nov 2022 07:42:21 +0000</pubDate>
      <link>https://dev.to/divine016/api-101-with-postman-api-2h8g</link>
      <guid>https://dev.to/divine016/api-101-with-postman-api-2h8g</guid>
      <description>&lt;h4&gt;
  
  
  Abstract:
&lt;/h4&gt;

&lt;p&gt;I attended an event at my school(University of buea) that talked about an introduction to API’s(API 101 with Postman).During this event i learned about what an API is, and  I was able to use the postman API  to generate a get and post request from the user. In this article I would be walking us through what an API is and also what postman API is.&lt;/p&gt;

&lt;h3&gt;
  
  
  what is an API??
&lt;/h3&gt;

&lt;p&gt;An API stands for Application Programming interface. It refers to a technology or mechanism  that helps two two softwares or  applications to communicate with each other using a set of defined protocols. In simple terms it’s a software that allows two applications talk to each other. .&lt;br&gt;
We use APIs in our everyday life. Some aplications of APIs include&lt;br&gt;
Weather snippets, login with uvw(at times when we want to visit a website and we are ask to login with google or even github.), google maps and just to name a few.&lt;/p&gt;

&lt;h3&gt;
  
  
  what is POSTMAN API??
&lt;/h3&gt;

&lt;p&gt;Now that we know what an API is all about we are going to talking about APIs with postman.&lt;/p&gt;

&lt;p&gt;Basically postman is an API  that help developers create and use APIs. It also allows collaboration so as to build better APIs. So postman is an API itself.&lt;br&gt;
Now that we know about APIs and postman I’m going to be talking about what I learned at the event.&lt;/p&gt;

&lt;p&gt;In other for you to use postman  you need to first create an account. So to do so we used thi &lt;a href="//bit.ly/api-collection"&gt;link&lt;/a&gt;&lt;br&gt;
Once you have created an account you can access their documentary from the &lt;strong&gt;Basics of API&lt;/strong&gt; at the top left of your screen. so as to see the various steps on how to get started in creating your own API.&lt;/p&gt;

&lt;p&gt;In conclusion the event was very amaizing and also the instructor &lt;strong&gt;@SalomeTambe&lt;/strong&gt; was really great. I learned alot about APIs and looking forward to creating my own API using postman API.&lt;/p&gt;

&lt;p&gt;Thank you for reading.&lt;/p&gt;

</description>
      <category>api</category>
      <category>writing</category>
      <category>postman</category>
    </item>
    <item>
      <title>MODERN PYTHON FOR EVERYONE: MASTERING PYTHON THE RIGHT WAY</title>
      <dc:creator>Kouti Divine</dc:creator>
      <pubDate>Fri, 04 Mar 2022 17:42:09 +0000</pubDate>
      <link>https://dev.to/divine016/modern-python-for-everyone-mastering-python-the-right-way-38h5</link>
      <guid>https://dev.to/divine016/modern-python-for-everyone-mastering-python-the-right-way-38h5</guid>
      <description>&lt;p&gt;Learning a programming language from scratch, especially when you are new to coding can be kind of difficult when you do not have the right tools and even the right people by you to guide you.&lt;br&gt;
Also, programming languages got specific task they can perform. They also have fields in which they work best. &lt;br&gt;
In this article, we would be discussing on the various techniques or ways that you as a beginner in coding can use so as to make yourself more conversant with coding. To be more specific we would use python and see the various methods that we could use so as to get your self to master python.&lt;/p&gt;

&lt;h2&gt;
  
  
  Introduction.
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;WHAT IS PYTHON?&lt;/strong&gt;&lt;br&gt;
Python is a high level general purpose programming language.&lt;/p&gt;

&lt;p&gt;Python is one of the most fastest growing programming language. It is a language that can be used in various domains  such as gamming, web development, data sciences, and even finance. Just to name a few&lt;br&gt;
Python is a high level programming language. Also it is  a very beginner friendly as compared to other programming languages.&lt;/p&gt;

&lt;p&gt;Now that we know what is Python, let us look at how you can master python.&lt;br&gt;
There are various aspects  that we need to take into account if we need to master any programming language and not only python.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;Determine why you wish to study that programming language&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Learn the basics &lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Practice using various projects&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Join a community&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Share your knowledge&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Lets discuss on the various ways that you may use if you want to master python.
&lt;/h2&gt;

&lt;h3&gt;
  
  
  1. Find why you want to learn python.
&lt;/h3&gt;

&lt;p&gt;Python can be very bulky to learn if you do not have an &lt;strong&gt;objective&lt;/strong&gt; or a &lt;strong&gt;goal&lt;/strong&gt; in mind.&lt;br&gt;
For example ; you could be passionate about web development so you could learn python so as to help you develope skills that you could use so as to build your website.&lt;br&gt;
You may want to learn python for web development or even for data science or even for game development.&lt;br&gt;
There are other things you could be passionate about and you could find the language that suites best to your passion and start learning  that language. &lt;/p&gt;

&lt;h3&gt;
  
  
  2. First learn the basics.
&lt;/h3&gt;

&lt;p&gt;Like in every programming language learning the basics is very important in order to master a programming language.&lt;br&gt;
You need to know the basics of python if you wish to know it perfectly well. They help us understand basic concepts of the language. &lt;br&gt;
you can read about python basics&lt;a href="https://dev.to/divine016/introduction-to-modern-python-basics-30lg"&gt;here&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  3. USE OF PROJECTS.
&lt;/h3&gt;

&lt;p&gt;Projects are very useful tools when you start coding. there are a variety of projects you could do. for example you like to build an app that people can use to download movies, or build a website for a restaurant and many other little or you could decide to build a calculator .It is said that &lt;strong&gt;The best way to learn is by practicing.&lt;/strong&gt; Since you have already gone  through the basic of python you could give your self little projects and also you could motivate your self when this project is completed. projects give you the possibility to learn more than just basics. It helps you learn more efficiently.&lt;br&gt;
Also you could get your self a python roadmap.&lt;br&gt;
A roadmap is a path that you follow so as to achieve your goals. &lt;br&gt;
Roadmaps are very important especially when you are new to coding.&lt;/p&gt;

&lt;h3&gt;
  
  
  4. Join a community .
&lt;/h3&gt;

&lt;p&gt;Communities are very important since they are there to encourage your every little step and achievements. Also a group of friends with whom you share the same passion can be very beneficial to you. Since you guys would work on projects that will increase your programming skills and also help you be more active.&lt;/p&gt;

&lt;h3&gt;
  
  
  5. Share your knowledge.
&lt;/h3&gt;

&lt;p&gt;Sharing your knowledge on what you know is one of the best things you could do to yourself. &lt;/p&gt;

&lt;p&gt;To conclude I would to give you this piece of advice&lt;br&gt;
Python is a really good programming language you should learn depending on the task you would like to achieve. Reading the right books help you increase your knowledge on programming. It is important to note that programming is something we do everyday. the more you put time into it the more you learn faster.&lt;br&gt;
At a start it is not advisable to spend lengthy hours on programming. You could first start by putting in one hour each day then as time goes by you should increase the number of hours. also using your free time to code could be of great help to you.&lt;/p&gt;

&lt;p&gt;I will end by giving you the name of some websites where you can learn python&lt;br&gt;
CODE ACADEMY&lt;br&gt;
W3SCHOOLS&lt;br&gt;
DATACAMP&lt;br&gt;
COURSERA&lt;br&gt;
UDEMY&lt;br&gt;
FREE CODE CAMP.&lt;/p&gt;

&lt;p&gt;Thank you for reading. You can reach out to me through this &lt;a href="https://twitter.com/DivineKouti?t=GJxYBO17TnixBrygRXtwyQ&amp;amp;s=08"&gt;link&lt;/a&gt;&lt;/p&gt;

</description>
      <category>programming</category>
      <category>python</category>
      <category>codenewbie</category>
    </item>
    <item>
      <title>Introduction to data structures and algorithms.</title>
      <dc:creator>Kouti Divine</dc:creator>
      <pubDate>Mon, 21 Feb 2022 17:44:06 +0000</pubDate>
      <link>https://dev.to/divine016/introduction-to-data-structures-and-algorithms-4739</link>
      <guid>https://dev.to/divine016/introduction-to-data-structures-and-algorithms-4739</guid>
      <description>&lt;p&gt;Like in every other programming language we need to know about its data structures as well as its algorithms. Python is not an exception.&lt;br&gt;
   This article is going to take us through the basics of data structures and algorithms🤗.&lt;/p&gt;
&lt;h2&gt;
  
  
  OBJECTIVES
&lt;/h2&gt;

&lt;p&gt;By the end of this article we should know more about;&lt;/p&gt;

&lt;p&gt;1- Definition of data structures and algorithms&lt;br&gt;
2- classification of data structures.&lt;br&gt;
3- Input and output functions , control flow functions. &lt;/p&gt;

&lt;p&gt;In order for us to know more about data structures and algorithms we need to first start by their definitions.🤓&lt;/p&gt;
&lt;h2&gt;
  
  
  &lt;strong&gt;&lt;u&gt;DEFINITIONS&lt;/u&gt;&lt;/strong&gt;
&lt;/h2&gt;
&lt;h2&gt;
  
  
  Data structure:
&lt;/h2&gt;

&lt;p&gt;A data structure refers to a particular way of organizing data in a computer so that it can be used effectively.&lt;br&gt;
&lt;strong&gt;Example&lt;/strong&gt;&lt;br&gt;
Data structures include&lt;br&gt;
Arrays, linked list, integers, float and many others.&lt;/p&gt;
&lt;h2&gt;
  
  
  Algorithms:
&lt;/h2&gt;

&lt;p&gt;An algorithm is a step by step set of instructions to process data for a specific purpose. Also an algorithm utilizes various data structures in a logical way to solve a specific computing problems. In other words an algorithm refers to a set of well elaborated, step by step instruction used to solve a particular task by the computer.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--RDPAFruF--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/bzmmb8bl3efgw8hxpfci.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--RDPAFruF--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/bzmmb8bl3efgw8hxpfci.png" alt="Image description" width="286" height="176"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;h2&gt;
  
  
  CLASSIFICATION OF DATA STRUCTURES.
&lt;/h2&gt;

&lt;p&gt;Data structures are classified into two main types which are,&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Primitive &lt;/li&gt;
&lt;li&gt;Non-primitive data structures.
&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--lvH7kJAL--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/0mfr2c8q8n8zv61bfb2u.png" alt="Image description" width="623" height="507"&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;
  
  
  PRIMITIVE DATA STRUCTURES.
&lt;/h2&gt;

&lt;p&gt;They are basic data structures that stores only one type of data. &lt;br&gt;
They include; float, integers, strings/characters, boolean, pointers.&lt;br&gt;
lets now define each of the following so we can have a better understanding of what each means.&lt;/p&gt;
&lt;h2&gt;
  
  
  Definition
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;&lt;u&gt;Integers.&lt;/u&gt;&lt;/strong&gt; &lt;br&gt;
 They refer to whole numbers ranging from negative infinity to positive infinity. Example of an integer is 2,-3.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;&lt;u&gt;Float&lt;/u&gt;&lt;/strong&gt;&lt;br&gt;
 They represent floating point numbers. They include fractions which are represented in  decimal format. EXAMPLE 2.666666.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;&lt;u&gt;Strings/Characters&lt;/u&gt;&lt;/strong&gt;&lt;br&gt;
 A strings is a sequence of characters. They can contain any sequence of characters, visible or invisible, and characters may be repeated.&lt;br&gt;
Example 'hello world.'&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;&lt;u&gt;Boolean/pointers&lt;/u&gt;&lt;/strong&gt;&lt;br&gt;
&lt;strong&gt;BOOLEAN&lt;/strong&gt;&lt;br&gt;
They refer to inbuilt data types which uses two values. Either TRUE or FALSE.&lt;br&gt;
They are interchangeable with 0 or 1.&lt;br&gt;
&lt;strong&gt;POINTER&lt;/strong&gt;&lt;br&gt;
Refers to a variable that hold an address in computer memory.&lt;br&gt;
that is it points to a specific location in memory.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--lN3Ulaha--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/6j2hoji23iqglbrq22y7.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--lN3Ulaha--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/6j2hoji23iqglbrq22y7.png" alt="Image description" width="213" height="237"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;h2&gt;
  
  
  NON-PRIMITIVE DATA STRUCTURES.
&lt;/h2&gt;

&lt;p&gt;Non- primitive data types are data types which are user defined and can store data of different types in a single entity. They are categorized into two parts which are linear and non linear data structures.&lt;/p&gt;

&lt;p&gt;Linear data structures is a sequential type of data structure. Meaning that all element in memory are store in a sequential manner.&lt;br&gt;
Examples are Arrays, linked list,  stack, queue.&lt;/p&gt;

&lt;p&gt;Non linear data structures is a random type of data structure. Example are trees and graph.&lt;/p&gt;

&lt;p&gt;Now lets talk of each of these detailly for better understanding.😊                                                                            &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;&lt;u&gt;ARRAYS&lt;/u&gt;&lt;/strong&gt;&lt;br&gt;
In pyhton arrays are not popular as in other programming languages like c, c++, java etc.&lt;br&gt;
In Python arrays are list that carry element of a particular data type. That is they hold elements of the same data type.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;&lt;u&gt;LIST&lt;/u&gt;&lt;/strong&gt;&lt;br&gt;
In python , list are easily recognized by square brackets[].&lt;br&gt;
example.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;number[]={1, 2, 3, 4}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;&lt;u&gt;STACK&lt;/u&gt;&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;It refers to a linear data structure that help user to either add of remove elements from a list.&lt;br&gt;
also it follows the principle of LIFO(last in first out.)&lt;br&gt;
Looking at a basic example of a stack is a a stack of plates. Also looking on the browser the last tab opened is usually the first in the history.&lt;br&gt;
when dealing with stack, we have two operations;&lt;br&gt;
push or pop.&lt;br&gt;
Push is the process of inserting elements onto the stack whereas pop is the process of removing elements from the stack. &lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--LXmB8yas--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/3pr56ou5yntf49p6d0nw.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--LXmB8yas--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/3pr56ou5yntf49p6d0nw.png" alt="Image description" width="259" height="194"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;&lt;u&gt;QUEUE&lt;/u&gt;&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;It refers to a linear data structure that follows the FIFO (First in first out). they can be used in CPU scheduling.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;&lt;u&gt;GRAPHS&lt;/u&gt;&lt;/strong&gt;&lt;br&gt;
This refers to a non-linear binary data structure.&lt;br&gt;
It's a collection of nodes that have data and are connected to other nodes.&lt;br&gt;
A graph in python consist of&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;collection of vertices.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;collection of edges represented as ordered pairs of vertices.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;&lt;u&gt;TREES&lt;/u&gt;&lt;/strong&gt;&lt;br&gt;
This refers to a non linear data structure in which data items are connected using references in a hierarchical manner.&lt;br&gt;
Each tree consist of a root node from which we can access each element of the tree. Leaf node and internal nodes.&lt;br&gt;
Each node is connected to it's child via a reference which is called edge.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--n-8KroUU--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/fnetbxcjmtvpkkpp93p0.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--n-8KroUU--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/fnetbxcjmtvpkkpp93p0.png" alt="Image description" width="287" height="176"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;h4&gt;
  
  
  ALGORITHM IN PYTHON.
&lt;/h4&gt;

&lt;p&gt;As we earlier defined an algorithm is a step by step procedure on how a specific task is to be performed by the computer.&lt;/p&gt;

&lt;p&gt;Example&lt;br&gt;
Let us write an algirithm that has to boil water.&lt;br&gt;
1-Put water in a pot and close the pot&lt;br&gt;
2=Put the the pot in the gas cooker &lt;br&gt;
3-Turn on the gas cooker.&lt;br&gt;
4-Once the water has boiled turn off the gas cooker.&lt;/p&gt;

&lt;p&gt;Learn more about algorithms &lt;a href="https://www.tutorialspoint.com/python_data_structure/python_algorithm_design.htm"&gt;here&lt;/a&gt;&lt;/p&gt;
&lt;h2&gt;
  
  
  INPUT OUTPUT FUNCTIONS
&lt;/h2&gt;

&lt;p&gt;Well when we talk of input it mean we are inserting information.&lt;br&gt;
In python, input functions are that which takes data from the user and convert it to a string.&lt;br&gt;
EXAMPLE&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;name= input('what is your name?')
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;the above code ask the user to type his/her name&lt;br&gt;
In python the print function is used as the output. that is the print function is that which is used to display information on the screen. and it cannot be modified.&lt;br&gt;
Example.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;name= input('what is your name?')
print('my name is', name.)
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;the above code ask the user to input type his name. when the user is done the computer print the next line  &lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--WsS-uiDy--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/l2komk3a4a0gf7a7d4wk.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--WsS-uiDy--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/l2komk3a4a0gf7a7d4wk.png" alt="Image description" width="800" height="419"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  CONTROL FLOW FUNCTIONS.
&lt;/h2&gt;

&lt;p&gt;control flow is the order in which the programs code executes.&lt;br&gt;
In python this is regulated by conditional statements, loops and functional calls.&lt;br&gt;
there are three main types of control structures that python supports.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Sequential&lt;/strong&gt;; &lt;br&gt;
The default mode.&lt;br&gt;
Here the execution of the program is done in a sequence that is one after the other.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Selection&lt;/strong&gt;; &lt;br&gt;
Used for decision and branching. Some include simple if statements, nested if statements, if-elif-else.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Repetition&lt;/strong&gt;; &lt;br&gt;
Used for looping, iteration or recursion. That is repeating the program over and over till a break.&lt;/p&gt;

&lt;p&gt;learn more about control flow statements &lt;a href="https://www.educative.io/edpresso/what-are-control-flow-statements-in-pyhton"&gt;here&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Thank you for reading.&lt;br&gt;
 You can connect with me on Twitter through this link&lt;br&gt;
&lt;a href="https://twitter.com/DivineKouti?t=Nd9otw4v4XJ3odOjL4MpXA&amp;amp;s=08"&gt;https://twitter.com/DivineKouti?t=Nd9otw4v4XJ3odOjL4MpXA&amp;amp;s=08&lt;/a&gt;&lt;/p&gt;




</description>
      <category>python</category>
      <category>algorithms</category>
      <category>beginners</category>
    </item>
    <item>
      <title>INTRODUCTION TO MODERN PYTHON: BASICS</title>
      <dc:creator>Kouti Divine</dc:creator>
      <pubDate>Fri, 11 Feb 2022 20:32:47 +0000</pubDate>
      <link>https://dev.to/divine016/introduction-to-modern-python-basics-30lg</link>
      <guid>https://dev.to/divine016/introduction-to-modern-python-basics-30lg</guid>
      <description>&lt;p&gt;By the end of this article you would learn the following;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;What is python, its origin and its application.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;The advantages of  python as compared to other languages.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Explain with examples the use of  data types and &lt;br&gt;
variables.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Explain the use of functions and methods in python.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Explain basic control flow if/else statements.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;u&gt;WHAT IS PYTHON&lt;/u&gt;&lt;/p&gt;

&lt;p&gt; Nowadays PYTHON is one of the most popular programming languages(PL). &lt;/p&gt;

&lt;p&gt;&lt;u&gt;&lt;strong&gt;Definition&lt;/strong&gt;&lt;/u&gt;&lt;br&gt;
Python is an interpreted high level, general purpose programming language. Its design philosophy emphasis code readabilaty with use of indentation.&lt;br&gt;&lt;br&gt;
&lt;u&gt;&lt;strong&gt;ORIGIN&lt;/strong&gt;&lt;/u&gt;&lt;br&gt;
 &lt;/p&gt;
&lt;p&gt; The PL PYTHON was designed in the late 1980`s by GUIDO VAN ROSSUM.  It was first released in 1991 as PYTHON 0.9.0. for the past years different versions of python have been released and the newest version was released in 2020 which is python 3.9. &lt;/p&gt;
&lt;br&gt;
&lt;strong&gt;FIELDS OF APLICCATION OF PYTHON&lt;/strong&gt;&lt;br&gt;
Since PYTHON is a general purpose PL it can be used in many fields like;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;AI and Machine learning&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Data analytics&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Data visualisation&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Web development &lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Game development &lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Finance.&lt;br&gt;
&lt;strong&gt;Advantages of python as compared to other languages.&lt;/strong&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Python is a user friendly PL.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Taking a PL like C we notice that python takes less lines so as &lt;br&gt;
to perform a certain task.&lt;br&gt;
IN PYTHON.&lt;br&gt;
&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F68en70sxcclp4zj7lb0t.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F68en70sxcclp4zj7lb0t.png" alt="Image description"&gt;&lt;/a&gt;&lt;br&gt;
IN C.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ffiev9fbvr62xuxkyngkk.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ffiev9fbvr62xuxkyngkk.png" alt="Image description"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Also comparing python with javascript, python can be used both 
as a scripting language and also as a programming language 
whereas javascript is  only a scripting language.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;u&gt;&lt;strong&gt;Getting started with python programming.&lt;/strong&gt;&lt;br&gt;
&lt;/u&gt;&lt;br&gt;
&lt;u&gt;INSTALLING PYTHON&lt;/u&gt;&lt;/p&gt;

&lt;p&gt;You can get the link &lt;a href="https://www.python.org/downloads/" rel="noopener noreferrer"&gt;here&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Once installed you can get the version of python installed by opening the cmd(comand prompt) in windows or the terminal in UNIX and then type python --version &lt;/p&gt;

&lt;p&gt;Also there are different IDE`s one can use such as VScode, Anaconda, Spyder, Pycharm just to name a few.&lt;/p&gt;

&lt;p&gt;Now that we are done with the installation let us dive into coding.&lt;br&gt;
In order to begin with any programming language we need to first look at the basics.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;&lt;u&gt;Variables&lt;/u&gt; and &lt;u&gt;Data types&lt;/u&gt;&lt;/strong&gt; &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Variables&lt;/strong&gt;&lt;br&gt;
 A Variable is a storage location paired with an associated symbolic name, which contains some known or unknown quantity of information refered to as value.&lt;/p&gt;

&lt;p&gt;it can be a word or a sentence or even a letter but not a number depending on the programer that is used to store a known or an unknown value..&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;`gender=" female"
 name='DIVINE'`
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;from the above gender and name are variables.&lt;br&gt;
&lt;strong&gt;&lt;u&gt;Rules for naming variables.&lt;/u&gt;&lt;/strong&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;you should not start a variable with numbers.&lt;br&gt;
EXAMPLE&lt;br&gt;
19gender is a wrong variable.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;special characters like $,!, /, \, # should not be added to your variable.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;your variable name should not be seperated. We only seperate variables using an underscore(_).&lt;br&gt;
EXAMPLE&lt;br&gt;
&lt;code&gt;choir_singer&lt;/code&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;In python variables are case sensitive.. &lt;br&gt;
&lt;strong&gt;Data types&lt;/strong&gt;&lt;br&gt;
They include;&lt;br&gt;
Numerical data type&lt;br&gt;
Strings&lt;br&gt;
List&lt;br&gt;
Tuples&lt;br&gt;
Sets&lt;br&gt;
Dictionary&lt;br&gt;
Range.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;You can learn more about each of these data types &lt;a href="https://www.google.com/amp/s/www.edureka.co/blog/variables-and-data-types-in-python/amp/" rel="noopener noreferrer"&gt;here&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;&lt;u&gt;functions and methods&lt;/u&gt;&lt;/strong&gt;&lt;br&gt;
&lt;strong&gt;FUNCTIONS&lt;/strong&gt;&lt;br&gt;
 A function is a block of code that runs when it is called.&lt;br&gt;
a function is defined with the &lt;strong&gt;def&lt;/strong&gt; keyword.&lt;br&gt;
&lt;strong&gt;Layout.&lt;/strong&gt;&lt;br&gt;
&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F3m9zc4gf54a7li8vz72l.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F3m9zc4gf54a7li8vz72l.png" alt="Image description"&gt;&lt;/a&gt;&lt;br&gt;
Learn more about functions &lt;a href="https://www.w3schools.com/python/python_functions.asp" rel="noopener noreferrer"&gt;here&lt;/a&gt;&lt;br&gt;
&lt;strong&gt;Methods&lt;/strong&gt;&lt;br&gt;
n Object-Oriented Programming, we have objects. These objects have both properties and behavior. Morover, properties of the object are defined by the attributes and the behavior is defined using methods. &lt;br&gt;
we have 3 types of methods which are&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;Instance Method&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Class Method&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Static Method&lt;br&gt;
Learn more about methods&lt;a href="https://www.analyticsvidhya.com/blog/2020/11/basic-concepts-object-oriented-programming-types-methods-python/" rel="noopener noreferrer"&gt;here&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;&lt;u&gt;Basic control flow and if/else statements&lt;/u&gt;&lt;/strong&gt;&lt;br&gt;
 In python, control flow or flow control statements refers to the order in which a code is being executed.&lt;br&gt;
They inchude:&lt;strong&gt;while&lt;/strong&gt;, &lt;strong&gt;for&lt;/strong&gt;, &lt;strong&gt;if&lt;/strong&gt;.&lt;br&gt;
Also control is regulated by conditional statements, loops and function calls.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fj8i73r3ru5s5e63zxik1.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fj8i73r3ru5s5e63zxik1.png" alt="Image description"&gt;&lt;/a&gt;&lt;br&gt;
&lt;strong&gt;Simple if/else statement.&lt;/strong&gt;&lt;br&gt;
Decision making is required when we want to execute a code only if a certain condition is satisfied.&lt;/p&gt;

&lt;p&gt;&lt;u&gt;Layout&lt;/u&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;
`if condition:
    code
else:
    code `
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;FLOWCHART&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fs0ki110b01yu0vxjid45.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fs0ki110b01yu0vxjid45.png" alt="Image description"&gt;&lt;/a&gt;learn more about control flow statements &lt;a href="https://www.educative.io/edpresso/what-are-control-flow-statements-in-python" rel="noopener noreferrer"&gt;here.&lt;/a&gt;.&lt;br&gt;
&lt;em&gt;THANK YOU FOR READING&lt;/em&gt;&lt;/p&gt;

</description>
      <category>beginners</category>
      <category>programming</category>
      <category>python</category>
      <category>codenewbie</category>
    </item>
  </channel>
</rss>
