Category: Python

  • Python Data Types : How they work

    Let’s embark on a journey into the fascinating world of Python data types, demystifying the concepts and shedding light on their connection with objects. As a Python enthusiast who loves to teach, I’m thrilled to guide you through this beginner-friendly exploration. Python Data Types: The Building Blocks of Information Imagine Python as a versatile toolbox,…

  • Variables and data types in Python

    Ah, Python variables and data types—a splendid place to embark on your coding journey! 🐍 You see, Python is like a linguistic marvel in the world of programming. For that reason, just as in a conversation, where words convey meaning, in Python, variables hold the keys to data. So, let’s delve into this captivating realm…

  • Speech Recognition and audio in Python

    In Python, a speech recognition package is a audio software library or module. It allows developers to incorporate speech recognition capabilities into their applications. Speech recognition packages enable a program to convert spoken language into text. As a result, it makes it possible to interact with software using voice commands or to transcribe spoken audio.…

  • How do I install PyCharm in Ubuntu?

    To install PyCharm on Linux using the JetBrains Toolbox, first open the official JetBrains website.There are two ways to install PyCharm.You can directly download PyCharm and after extracting use the “cd” command to go to the “bin” folder.Here you can find the executable file “pycharm.sh”. When you execute it, PyCharm will run from your terminal.But…

  • Which Programming Languages ​​Most In Demand In 2023?

    According to the industry trends, we can list the Programming Languages ​​Most In Demand In 2023. Let’s see the list at a glance. In 2023 we have already reached the middle of February. And the pattern shows the topper of the most in-demand programming languages is Python. Python is a high-level, interpreted language used in…

  • Pandas sort by column name

    Pandas sort by column name is nothing but a certain type of data analysis. For beginners especially, we can do it to give an idea. Think about the data structure as a spreadsheet where we have multiple rows and columns. Right? Now we can use Pandas to handle a large amount of data because this…

  • Pandas describe method

    In the previous section we have learned how we can play with pandas head and tail methods. Pandas describe method is also important. Why? Because pandas describe method generates descriptive statistics that we need especially for studying statistical data.  Before moving ahead, let’s take a look at the code first. Now as we take a…

  • What is enumerate in Python

    The enumerate in Python is a built-in function. It takes an iterable object. And returns an iterator that produces tuples. The iterable object could be a list, tuple, or string. Moreover, it contains the index and the value of each element of the object. Here’s an example. Here we can use enumerate to iterate over…

  • Pandas dataframe operations for Machine Learning

    As we said before Pandas is one of the most useful machine learning libraries. However, we need to know Pandas dataframe operations. Especially those operations that we need everyday to train and test data for machine learning. In our previous sections we have seen how we can import different libraries like Pandas, scikit-learn, Matplotlib, and NumPy. Each of them…

  • What is for loop in Python give example?

    The for loop in Python is one of the main looping constructs. Usually we use the for loop when we want to iterate over the sequence.  This sequence could be a collection, such as tuple, list, or even a string. As a result of iteration, the placeholder variable takes every item as we iterate over…

  • Python while loop

    In our previous section we have seen examples of if-else. In this section, we will take a look at Python while loop. The common question that comes to our mind is which one is faster? For or while loop?  In the Java section, we have tried to find out the answer. You may have a…

  • if else in python

    The if else in Python is a part of flow control. In this section we will try to understand how the if-else block works in Python. If you are new to Python, you may visit the other beginner friendly articles in the Python Primer category. Flow control plays an important role not only in Python…

  • Namespace and scope in Python

    Namespace and scope in Python are very much interrelated. In this section, we will take a look at this very important concept. Before giving an example we can take a look at the file systems in a computer. Suppose in C drive, we try to save a file under the same name. Will it allow…

  • Train machines through machine learning

    Through machine learning we train machines to perform various actions. A simple example of this action is spam filtering in email. But as long as we talk about these actions that machine learning performs, the sky’s the limit. Let’s take a look at other various tasks or actions. These actions might include predictions, recommendations, estimations,…

  • Operators Python: Comparison, Logical and Identity

    In the last section we have seen arithmetic operators in Python. However we didn’t discuss Arithmetic Operators Python precedence. Therefore that should be the first task that we should address. First of all, what is arithmetic precedence? When we have many operations at our hands, such as the following example. What will be the value…

  • What are operators in Python

    Why do we use operators in Python? For one reason of course. To perform various kinds of operations on variables. Arithmetic operations like addition, subtraction, multiplication or division are nothing new to us. Right?  As a result, we know how to use those operators. However, a programming language needs a lot more than that.  If…

  • How do you show Python output

    We can show Python output in many ways. In other words, there are many ways that we can adopt to show the output in Python. In this section, we will see all the alleys and backstreets to display the output. Firstly, let us clear a basic point in mathematics and programming.  A function primarily handles…

  • How Python Dictionary functions work

    In our previous section, we have seen a few examples of Python dictionary functions. In this section we will discuss more. Let’s start with the popitem() method. This method removes and returns the last key, value pair inserted into the Python Dictionary. However, the popitem() doesn’t take any arguments. Let’s take a look at one…

  • What are Python dictionary functions

    We have learned how a Python dictionary works. However, we use Python dictionary functions without knowing that they are built-in methods. In the previous sections we have seen how the  Python Set and Dictionary belong to the collections or data structures. We have also discussed lists and tuples. However, lists and tuples differ in nature.…

  • Dictionary functions in Python

    Dictionary functions are a few built-in methods in Python. Using these functions we can do many operations on a dictionary. However, in the previous section we have seen how a python dictionary behaves as a mutable data structure. But promised to show the delete method in the later section. Therefore, before discussing the dictionary functions…

  • Dictionary is mutable in python

    A Dictionary is mutable in Python. What does that mean? In short, it means we can use the concept of CRUD with a dictionary. Let’s clarify the concept a little bit. Actually it’s simple. CRUD represents four words – C for Create, R for retrieve, U for update, and D for delete. In the coming…