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 Farhan Muhamed
101 articles
Building an Amazon Keyword Research Tool with Python
Amazon keyword research is a critical step for sellers, marketers, and product teams who want to understand how customers discover products. Keywords influence product titles, descriptions, backend search terms, and advertising performance. Manually researching keywords through the Amazon interface is time-consuming and limited. Results are personalized and location-dependent, making them difficult to analyze at scale. In this tutorial, you'll learn how to build an Amazon keyword research tool using Python that retrieves search results and analyzes recurring keywords. Prerequisites To follow this tutorial, you should have ? Basic knowledge of Python (functions, lists, dictionaries) Python ...
Read MoreAdditive Secret Sharing and Share Proactivization ñ Using Python
Additive Secret Sharing and Share Proactivization are cryptographic techniques to share a password or other confidential data among a group of people. In this article, we will explain these techniques and implement Python code to demonstrate them. Additive Secret Sharing Additive secret sharing is a technique used in cryptography to share a secret string or a password among multiple parties, such that all of the parties must collaborate to reconstruct the secret. For example ? Original Secret Key: 1234 Generated five Shares: [-488, -55, -417, -720, 2914] Reconstructed Secret: 1234 Explanation: The original secret ...
Read MoreAdjusting the heights of individual subplots in Matplotlib in Python
Matplotlib is a powerful Python library for creating graphs and plots. When working with multiple subplots, you often need to adjust their individual heights to better display your data. This article demonstrates how to control subplot heights using two effective methods. Understanding Subplots A subplot is a smaller plot within a larger figure. You can arrange multiple subplots in rows and columns to compare different datasets or show related visualizations together. Figure with 4 Subplots (2×2) Subplot ...
Read MoreAdjusting Text background transparency in Matplotlib
The matplotlib library in Python allows us to create graphs and plots for data visualization. This library has several built-in functions to style plots, such as changing colors, adding titles, setting backgrounds, labels, and adjusting layouts. In this article, we will learn how to adjust the transparency of text backgrounds in matplotlib plots. Text Backgrounds in Matplotlib In matplotlib, text backgrounds refer to the area behind text elements such as titles, labels, and annotations in a plot. By default, the background of text is transparent, but we can change it to a solid color or a semi-transparent color ...
Read MoreAdding Tuple to List and vice versa in Python
In Python, both tuples and lists are used to store data in sequence. Python provides built-in functions and operators that allow us to easily add elements of a tuple into a list and elements of a list into a tuple. In this article, we will explain various methods to perform these conversions, along with example codes. Problem Scenarios Scenario 1: Adding Tuple Elements to List You are given a list and a tuple as input, your task is to add tuple elements into the list and print the list as output. For example: # ...
Read MorePython Program To Find the Smallest and Largest Elements in the Binary Search Tree
In this article, we will explain how to find the minimum and maximum values in a binary search tree (BST), with implementation in Python. A binary search tree is a data structure that stores data in a sorted order such that for every node, the left subtree contains values less than the node's value, and the right subtree contains values greater than the node's value. So the leftmost node will have the minimum value, and the rightmost node will have the maximum value. Problem Statement Given the root node of a binary search tree, find the node ...
Read MoreAddition of tuples in Python
In Python, tuples are used to store an immutable sequence of elements. In this article, we will learn different methods to implement a Python program to add corresponding elements of tuples. Here, you are given two equally sized tuples in Python and your task is to create a new tuple containing sum of corresponding elements of the tuples. Consider the following example scenario − Scenario # Input Tuples: tup1 = (3, 6, 9, 45, 6) tup2 = (11, 14, 21, 0, 6) # Expected Output: (14, 20, 30, 45, 12) # The corresponding elements ...
Read MoreProgram to count number of unique binary search tree can be formed with 0 to n values in Python
In this article, we will discuss a problem that involves counting the number of unique binary search tree (BSTs) that can be formed with a given number of nodes. We will explain the problem, test cases, its solution, and provide a Python implementation. Problem Statement Given an integer n, we need to find how many structurally unique BSTs can be formed using values from 1 to n. This is known as the Catalan number problem in computer science. Example 1 Input: n = 3 Output: 5 Explanation: With 3 nodes (values 1, 2, ...
Read MoreAdding two Python lists elements
In Python, a list is a built-in data structure that stores an ordered collection of multiple items in a single variable. Lists are mutable, meaning we can add, remove, and change their elements. This article demonstrates how to add corresponding elements of two Python lists element-wise. Given two equal-sized lists, we need to create a new list containing the sum of corresponding elements from both lists. Example Scenario # Input lists list1 = [3, 6, 9, 45, 6] list2 = [11, 14, 21, 0, 6] # Expected output: [14, 20, 30, 45, 12] # Explanation: ...
Read MoreSearching for minimum and maximum values in an Javascript Binary Search Tree
In this article, we will explain how to find the minimum and maximum values in a binary search tree (BST), with implementation in JavaScript. A binary search tree is a data structure that stores data in a sorted order such that for every node, the left subtree contains values less than the node's value, and the right subtree contains values greater than the node's value. So the leftmost node will have the minimum value, and the rightmost node will have the maximum value. Find Minimum and Maximum in a BST Given root node of a binary search ...
Read More