Article Categories
- All Categories
-
Data Structure
-
Networking
-
RDBMS
-
Operating System
-
Java
-
MS Excel
-
iOS
-
HTML
-
CSS
-
Android
-
Python
-
C Programming
-
C++
-
C#
-
MongoDB
-
MySQL
-
Javascript
-
PHP
-
Economics & Finance
Articles by karthikeya Boyini
1,421 articles
How to Test your Broadband Speed from Linux Terminal
Testing your broadband internet speed from the Linux terminal is useful for network diagnostics and monitoring. The speedtest-cli tool provides a command-line interface to test download/upload speeds using speedtest.net servers. Installing Python pip First, install Python pip which is required for installing speedtest-cli ? $ sudo apt-get install python-pip The output will show package dependencies being installed ? Building dependency tree Reading state information... Done The following packages were automatically installed and are no longer required: libbs2b0 libopusfile0 libqmmp-misc libqmmpui0 libsidplayfp linux-headers-4.2.0-27 linux-headers-4.2.0-27-generic linux-image-4.2.0-27-generic linux-image-extra-4.2.0-27-generic ...
Read MoreFish – A Smart and User-Friendly Interactive Shell for Linux
The Fish (Friendly Interactive Shell) is an innovative command-line shell for Linux and Unix-like systems. Unlike traditional shells that disable features by default to save resources, Fish enables powerful features out of the box to enhance user productivity. Key Features of Fish Shell User-friendly and interactive interface Smart autosuggestions based on command history Web-based configuration interface Syntax highlighting with 256 terminal colors X clipboard integration Built-in error checking and validation Comprehensive help system Arrow key navigation for suggestions Installing Fish Shell Step 1: Install Python Software Properties First, install the required dependencies − ...
Read MoreUsing Iterations in Python Effectively
In this article, we will learn about different iteration methods in Python and their effective implementation. Python provides several approaches to iterate through data structures, each with its own advantages and use cases. Using While Loop with Index This method uses a while loop with manual index management ? languages = ("Python", "C", "C++", "Java") print("The topics available on TutorialsPoint are:") i = 0 while (i < len(languages)): print(languages[i]) i += 1 The topics available on TutorialsPoint are: Python C C++ Java This ...
Read MoreUsing List as Stack and Queues in Python
In this article, we will learn how to implement Stack and Queue data structures using Python lists. Both are fundamental data structures with different ordering principles: stacks follow LIFO (Last In First Out) while queues follow FIFO (First In First Out). We'll cover the core operations for both structures − Insertion operation (Push for stacks, Enqueue for queues) Deletion operation (Pop for stacks, Dequeue for queues) Display / Traversing operation ...
Read MorePython Rational numbers (fractions)
Any number which can be expressed as a quotient or fraction in the form of p/q is called a rational number. The fractions module of Python's standard library provides functionality for rational number arithmetic with exact precision, avoiding floating-point rounding errors. Creating Fraction Objects The fractions module defines a Fraction class that can be constructed in various ways ? Using Numerator and Denominator from fractions import Fraction n1 = Fraction(2, 5) print(n1) n2 = Fraction(6, 15) # Automatically reduced to lowest terms print(n2) n3 = Fraction(10, 1) print(n3) n4 = ...
Read MoreSocket Programming with Multi-threading in Python?
Socket programming with multi-threading allows a server to handle multiple clients simultaneously. While a basic socket server can only serve one client at a time, multi-threading creates separate threads for each client connection, enabling concurrent communication. Multithreading Concepts Multithreading is a core concept in modern programming languages, especially Python, due to its simple thread implementation. A thread is a sub-program within a program that executes independently while sharing the program's resources like memory. When multiple threads execute simultaneously within a single process, it's called multithreading. Python Threading Modules Python provides two modules for thread implementation − ...
Read MorePython library PyTube to download youtube videos
YouTube is the world's most popular video sharing platform. Sometimes you want to download videos for offline viewing, but most YouTube downloader apps have restrictions or cost money. Instead, you can create your own Python program using the PyTube library to download YouTube videos easily. PyTube is a lightweight, dependency-free Python library that allows you to download videos and audio from YouTube. Since it's not a standard library, you need to install it first ? Installation pip install pytube Collecting pytube Downloading pytube-15.0.0-py3-none-any.whl Installing collected packages: pytube Successfully installed pytube-15.0.0 ...
Read MoreWebsite Blocker Using Python
Website blockers are commonly used in corporate environments to restrict access to social media and entertainment sites during work hours. Instead of relying on third-party applications, we can create our own custom website blocker using Python's built-in libraries. Prerequisites Python 3.x installed Basic knowledge of Python Administrator privileges (required to modify system files) How It Works Every operating system has a hosts file that maps hostnames to IP addresses. By redirecting blocked websites to the local loopback address (127.0.0.1), we can prevent access to specific sites during designated hours. ...
Read MoreDevelop Notepad using Tkinter in python
Tkinter is a standard GUI library in Python that enables developers to create desktop applications. In this tutorial, we'll build a fully functional notepad text editor with file operations, editing features, and menu functionality using Tkinter. Prerequisites Python installed (3.x recommended) Tkinter module (comes pre-installed with Python) Note: Tkinter is included as a standard library with Python 3.x installations. Notepad Menu Structure Our notepad will contain four main menu categories with their respective sub-items: File Menu: New, Open, Save, ...
Read MorePrint Colors of terminal in Python
In the terminal, if you want to make text appear in colored mode, there are numerous ways in Python programming to achieve it. Python offers several modules and built-in methods to add colors to terminal output. Using the termcolor Module The termcolor module provides ANSI color formatting for terminal output. It's one of the most popular libraries for adding colors to text. Installation First, install the termcolor module using pip − pip install termcolor Basic Usage Here's how to use termcolor to print colored text − import sys from ...
Read More