All the programs explained with code in detail

Photo by Christopher Gower on Unsplash

Tkinter is one of the best modules to use in the Python programming language. It is specifically used to create a Graphical User Interface. With this module, we can create some fantastic programs. In this article, we try to create a simple yet interesting program. We are specifically going to focus on simple GUI to understand Tkinter better.

1. A Digital Clock with Tkinter:

A program to create a digital clock with Tkinter to display the time.

In this program, we use two packages: time and Tkinter. By using the time package we display the local time with the help of the strftime function.


Write and Read Data Structure Into A File

Photo by Beatriz Pérez Moya on Unsplash

JSON(JavaScript Object Notation) is a syntax used to transfer data between client and server. JSON is used in many popular languages like Python, C#, C++, Perl, Java, etc. Using JSON helps with building cross-platform applications. In this article, let us write, read JSON files with Python.

What are the advantages of JSON files:

  • The JSON file is an ideal format to transfer data between a server and web application, and this is an excellent alternative to an XML file.
  • Developers use this to dump data structures they are working on into a file and load it when required.
  • It is…

Fun Python programs explained with code

Photo by Christopher Gower on Unsplash

Python is an interesting programming language. Try these programs with some fantastic packages and modules to learn more about Python. There are so many things you can do with Python. In this article, we are trying to work around automation and some social media with Python scripts

1. Instagram Profile Picture Downloader:

A python program to download Instagram profile pictures with a Python package.

In this program, we use a Python package to download the image. We use a package in this program that has to be installed. To install pip install instaloader syntax should be used. Then import this package using import instaloader syntax…

A unique module explained with some programs

Photo by Maxwell Nelson on Unsplash

One of the most interesting built-in modules in Python is secrets which were released in Python 3.6. It is popularly known to produce data that are close to true randomness. With the help of this package, you can produce cryptographically strong data. Some data produced with this method can be used in passwords, tokens, OTP( One Time Password). In this article, let us learn about the secrets module and its methods and how it is different from random modules.

Why is the secrets module better than the random module? Although you can generate random data from a random module, it…

All the keywords are explained in detail with code

Photo by James Harrison on Unsplash

Keywords are the basics of Python programming that everyone must know. These are the reserved words in Python. Some keywords are interesting and yet rarely used. That is why it is essential to take into account how many keywords are there and their functionality. Each keyword is unique and has a different function. In this article, I will try to explain all the 35 Python keywords in detail.

1. async and await:

All the programs by default run synchronously. With these keywords, you can make a program run asynchronously. …

Games that help you to learn programming faster

Photo by Axelle on Unsplash

Who said learning programming shouldn’t be fun? Everyone loves playing games, and learning while playing a game is fun. These games provide you with challenges, rewards, and badges to encourage you to learn. When there is a community to compete, it makes learning fun and exciting. Here are the top-five games which help with learning different programming languages.

1. Code Combat:

This game tops my list because it is one of the best games to play and understand programming languages. The graphical user interface(GUI) used in this game is fantastic. In this game, when you complete a level/program there are rewards to keep…

A schedule and resources to cover python basics

Photo by Alejandro Escamilla on Unsplash

Python is one of the popular programming languages. Mastering Python basics is crucial. Python has an easy and simple code style, which makes it easy to learn. It is also the language that is used in developing many media networks like Instagram, Amazon, Uber, Netflix, and many more.

In this article, let us try to learn the basics of python in 10 days. This article is written assuming you have some programming knowledge.

Day 1- Installation and First program:

First, you need an IDE for running your python script. If you already don’t have one, Pycharm is one of the best IDE. The community version is…

Essential tips & tricks for better programming

Image Created By Author Using

1. Permutation with itertools:

In this program, we import the built-in module called itertools. With itertools, you can find all the permutations of the given string. In itertools there are numerous methods, you can try a combination and other methods.

2. One-Line Condition Expression:

This conditional expression was added to Python 2.5 version. This can be used with A if condition else B syntax. First, the condition is evaluated and returns based on the boolean value of the condition. If it is true it returns A or else if it is false it returns B.

3. Reverse a string:

In this program, we use an extended slice to reverse the…

Must know functions in Python explained with code

Photo by Christopher Gower on Unsplash

In this article, five important functions are explained in detail with code. These functions are simple yet the most powerful function in Python. Python has many libraries and built-in functions. Understanding these functions and using them properly helps with efficient programming.

1. Lambda Function:

One of the most powerful functions in Python also known as the anonymous function. It is known as anonymous because we can instantiate and declare a function without a name. If you have a single operation to be executed, the lambda function is extremely useful instead of declaring a traditional function. …

Creating, merging, locking, unlocking, and watermarking explained with code

Image Created By Author Using

PDF files are extensively used in many fields and learning to handle PDF files is important. In this article, we try to do different operations on the PDF file like locking, unlocking, merging, creating, and adding watermark with python script.

1.Locking or encrypting a PDF file:

A program to lock the PDF file with the given password with Python.

Some PDF files with important information need to be protected. Let us try to do this with a python script. Install the python package used in this program with pip install PyPDF2 syntax.

Note: Two methods PdfFileReader and PdfFileWriter are used, to read and write a…

Swathi Arun

2x Top Writer | Art | Travel | Engineer | Writer I am a programmer who loves to write about my traveling experience.

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