Use these code snippets to solve everyday problems

Photo by Toa Heftiba on Unsplash

Python has seen enormous growth in its user base over recent years. Beginner programmers are opting for Python as their first language seeing its simple syntax and its applications.

In this article, I’ll share some python code snippets that can be used to solve Python’s day-to-day problems. Let’s get started!

1. Merge two dictionaries

Merging multiple dictionaries has become easier after Python 3.5. We can merge multiple dictionaries in a single line using (**) operator. We need to pass dictionaries in {} along with (**) operator, and it's done.

Syntax: {**dictionary1, **dictionary2}

2. Chain Comparison

This…


Python functions that are amazing and useful

Photo by bruce mars on Unsplash

Python built-in functions are very handy and easy-to-use. They make python scripting faster and help to optimize the code. Built-in functions not only save our time but also help us avoid unnecessary lines of code.

Python has got many built-in functions that we can use to improve the clarity of the code and decompose a complex problem into simpler pieces of code. Not many people know about these built-in functions, once you come to know about these built-in functions, you will be handy to them.

In this article, I will share the most useful eight python built-in functions that I…


Some lesser-known but useful python features

Photo by Alex Kotliarskyi on Unsplash

Python is one of the most popular languages among developers. It is known for its easy syntax and its use in various areas, especially in data science. It also has one of the most active open-source developer community that continuously keeps adding new features in Python.

Python is equipped with 290,000+ packages that are available in Python Package Index(PyPi). These packages are widely used for different purposes such as web development, machine learning, scientific computing and many more.

The more you learn about Python, the more you know about its features and applications in different areas. …


Python libraries and their uses in data science

Photo by Hugo Perez Neto from Pexels

Python has been one of the favourite languages for Data Scientists for a while. It has gained huge popularity in the data science field due to its rich libraries used for the whole data-driven decision-making process.

These libraries are used at various data science steps such as loading the data, data processing, data visualization and modelling. In python, these libraries are used for automating tasks, predicting outcomes and get business intelligence insights.

In this article, I will introduce some Python libraries that are useful for data scientists, data engineers and machine learning engineers. Let’s get started!

1. Pandas

Pandas is an open-source…


Try different hairstyles with hair simulation effect

Photo by Ronise Da Luz on Unsplash

Hair simulation is a great way to simulate different but realistic hairstyles. The Hair Simulation effect lets you know which hairstyle suits your face, and it’s quite a lot of fun. We can simulate short, long, and different color hairstyles in Lens Studio.

In Snapchat’s Lens Studio, we will use the Hair Simulation template to try and simulate some beautiful hairstyles.

In this article, we will learn to simulate a wide range of beautiful and unique hairstyles that will give you a realistic experience. Let’s get started!

Step 1: Set up a New Project in Lens Studio

Open Lens Studio. You will see many recommended templates. …


All you need to know about types of chatbot

Photo by NeONBRAND on Unsplash

Chatbots are everywhere nowadays. You must have interacted with a chatbot many times. Whether it's while booking a flight ticket or while refunding your ticket price.

Siri, Alexa and Google Assistant are the best examples of chatbots that we interact with on daily basis. So, what are these chatbots?

A chatbot is a piece of software that is used in different applications and websites to interact with users and customers and assist them in performing a particular task.

Today almost every company, which is having a large user base, is using a chatbot to engage with its users.

Worldwide many…


Programming languages and their uses that you should know

Photo by George Becker from Pexels

There are many programming languages that make it challenging to choose the right one to start with. If you are looking for a programming language to start your career with, this article is for you.

In this article, I’ve discussed some popular programming languages and their uses. Let’s get started!

1. Python

Python is one of the most popular general-purpose and open-source programming language. It was developed by Guido van Rossum in 1991.

One reason for Python’s popularity is its beginner-friendly syntax, which makes python code more readable. A person with no programming background can start coding with Python. …


Speed up your Python code

person in running shoes climbing stone steps
person in running shoes climbing stone steps
Photo by Bruno Nascimento on Unsplash

Python is one of the most popular programming languages among developers. It is used everywhere, whether it’s in web development or machine learning.

There are many reasons for its popularity, such as its community support, its amazing libraries, its wide usage in machine learning and big data, and its easy syntax.

Despite having these many qualities, Python has one drawback, which is its slow speed. Being an interpreted language, Python is slower than other programming languages. Still, we can overcome this problem using some tips.

In this article, I will share some Python tricks, using which we can make our…


Walkthrough some common data science questions asked in interviews

Photo by Andrea Piacquadio from Pexels

Data Scientist is one of the most demanding roles in the IT industry these days. The popularity of data science has been increasing over the years. Many companies are hiring data scientists to grow their business and increase customer satisfaction.

Data, referred to as the Oil of the 21st century, allows data scientists to make decisions based on the pattern present in the data. Data scientists must have skills such as statistics, mathematics, machine learning, and database.

This article is for you if you are preparing for a data science interview. …


Know these things for a better trading experience

Photo by Alesia Kozik from Pexels

You must have heard about the words ‘intraday trading’, ‘stock market crash.’ These are the buzzing words nowadays. More and more people are investing in the stock market to earn money in a short period.

The stock market can help you earn a lot of money, but at the same time, you can lose all your money if you invest in the stocks randomly without knowing a single thing about that stock.

Investing in stocks is not just a number game, but it’s also not far away from numbers if you understand what’s going in the stock market or with…

Pralabh Saxena

Software Developer | Data Science | Love to write and express. About me https://linktr.ee/pralabhsaxena

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store