Found 27104 Articles for Server Side Programming

Python for IoT Applications: Controlling and Monitoring Devices

Prince Yadav
Updated on 28-Jul-2023 14:55:56

1K+ Views

Being passionate enthusiasts of Internet of Things (IoT) technologies, we find ourselves constantly astounded by the immense possibilities this field presents. IoT has revolutionized our interaction with the world by providing the ability to connect and control devices remotely. In this regard, Python has emerged as a pivotal language that facilitates these functionalities. In this article, we will explore Python for IoT applications, with a specific focus on its capacity to control and monitor devices. Come along as we uncover the immense power of Python in the realm of IoT. Python has earned its reputation as the preferred language ... Read More

Convert Timestamp To Readable Date/Time In PHP

Pradeep Kumar
Updated on 28-Jul-2023 15:07:48

7K+ Views

What is PHP ? Popular server-side scripting language PHP (Hypertext Preprocessor) is mostly used for web development. For building dynamic web pages and applications, it offers a dynamic and interactive environment. Dynamic content can be produced on the server using PHP code that is inserted in HTML markup and performed on the client's web browser. PHP provides a wide range of features, including database connectivity, session management, form handling, and file manipulation, thanks to its rich libraries and frameworks. It is renowned for being straightforward, adaptable, and widely used, making it a top option for creating dynamic websites and web ... Read More

Count of N-length binary strings that are repeated concatenation of a substring

Thanweera Nourin A V
Updated on 28-Jul-2023 15:22:00

72 Views

The aim of this article is to implement a program to count of N-length binary strings that are repeated concatenation of a substring. The goal is to determine how many binary strings of the length N can be created by repeatedly concatenating a single substring of a given text, provided a positive integer called N. Problem Statement Implement a program to count of N-length binary strings that are repeated concatenation of a substring. Sample Example 1 Let us take the Input, N = 3 Output: 2 Explanation Listed below are the feasible binary string of length N=3 with ... Read More

Count of N digit numbers not having given prefixes

Thanweera Nourin A V
Updated on 28-Jul-2023 15:20:37

58 Views

Here the problem is to determine the total number of strings of the length N containing characters '0' through '9' provided an integer N with an array of string prefixes pre[]. such that none of the strings can contain the provided prefixes. The aim of this article is to implement a program to find the count of N digit numbers not having given prefixes. A collection of various strings is referred to as an array in the C programming language because an array is a linear grouping of data pieces of a similar type. As we already know, the string ... Read More

Comparison between Static and Instance Method in PHP

Pradeep Kumar
Updated on 28-Jul-2023 15:00:02

231 Views

What is Static Method? In PHP, a static method is a method that belongs to the class itself rather than an instance (object) of the class. It can be accessed directly using the class name, without the need to create an instance of the class. Example Output 25 27 In the example above, we have a MathUtility class with two static methods: square() and cube(). These methods perform simple mathematical operations and return the result. Since the methods are static, we can directly access them using the class name followed by the :: operator, without ... Read More

Binary Search in PHP

Pradeep Kumar
Updated on 28-Jul-2023 19:45:43

977 Views

What is Binary Search? Binary search is a search algorithm used to find the position of a target value within a sorted array (or list) efficiently. It works by repeatedly dividing the search range in half and comparing the middle element with the target value. The binary search algorithm follows these steps: Start with the entire sorted array. Set the left pointer to the first element of the array and the right pointer to the last element. ... Read More

How to open an image from the URL in PIL?

Tarun Singh
Updated on 31-Jul-2023 10:33:37

3K+ Views

PIL (Python Imaging Library) is a widely used Python library that enables developers to work with image files. It offers a broad range of functionalities for manipulating and handling image files, such as opening and resizing them, converting between different formats, and more. One frequently encountered task when working with images involves opening an image file from a URL. This is especially useful when working with images that are stored on a remote server, such as those obtained from an online database or a website. In this article, we will learn how to open an image from the URL in ... Read More

How to not get caught while web scraping?

Tarun Singh
Updated on 31-Jul-2023 10:31:01

119 Views

Market research, price monitoring, and content aggregation are just a few examples of the myriad of purposes for which web scraping is utilized and has gained widespread popularity. Although web scraping entails extracting data from websites, there are quite a few legal and ethical concerns surrounding this controversial practice, particularly when it is conducted without the consent of the website's owner. A number of website owners implement anti-scraping measures to thwart potential scrapers, while others even take legal action. In this article, we will learn how not to get caught while web scraping. Why Web Scraping can be Complicated? Web ... Read More

How to normalize a NumPy array so the values range exactly between 0 and 1?

Tarun Singh
Updated on 10-Aug-2023 16:01:21

2K+ Views

NumPy is a powerful library in Python for numerical computing that provides an array object for the efficient handling of large datasets. Often, it is necessary to normalize the values of a NumPy array to ensure they fall within a specific range. One common normalization technique is to scale the values between 0 and 1. In this article, we will learn how to normalize a NumPy array so the values range exactly between 0 and 1. We will see the different approaches that can be used to achieve this using NumPy, along with syntax and complete examples. Approaches There are ... Read More

How to Merge Two Pandas DataFrames on Index?

Tarun Singh
Updated on 31-Jul-2023 10:23:16

2K+ Views

Merging two Pandas DataFrames on index can be useful in many data analysis scenarios. For instance, you might have two datasets with different features or data points, but both share a common index. In this case, merging the two DataFrames can help you combine the data in a meaningful way. In this article, we will learn how to merge two Pandas DataFrames based on an index in Python. We will go through the complete steps involved in the merging process and illustrate each step with code examples. What is DataFrames in Pandas? One of Pandas library's most crucial data structures ... Read More

Advertisements