title
stringlengths
3
221
text
stringlengths
17
477k
parsed
listlengths
0
3.17k
Area of the largest rectangle possible from given coordinates - GeeksforGeeks
07 Apr, 2021 Given two arrays arr1[] and arr2[] of N denoting N coordinates of the form (arr1[i], 0) and M positive integers denotingM coordinates of the form (arr2[j], 1) where 1 ≤ i ≤ N and 1≤ j ≤ M. The task is to find the area of the largest rectangle that can be formed using these coordinates. Print 0 if no rectan...
[ { "code": null, "e": 26717, "s": 26689, "text": "\n07 Apr, 2021" }, { "code": null, "e": 27043, "s": 26717, "text": "Given two arrays arr1[] and arr2[] of N denoting N coordinates of the form (arr1[i], 0) and M positive integers denotingM coordinates of the form (arr2[j], 1) wher...
Spacing between boxplots in ggplot2 in R - GeeksforGeeks
18 Jul, 2021 In this article, we are going to see how to add space between the boxplots in ggplot2 using R programming language. Dataset in use: Crop_recommendation Here we will use width attributes to define space between the boxplot. In this the value is passed to the attribute. Syntax: geom_boxplot(width) Program: R...
[ { "code": null, "e": 26487, "s": 26459, "text": "\n18 Jul, 2021" }, { "code": null, "e": 26603, "s": 26487, "text": "In this article, we are going to see how to add space between the boxplots in ggplot2 using R programming language." }, { "code": null, "e": 26639, ...
C# | Insert() Method - GeeksforGeeks
31 Jan, 2019 In C#, Insert() method is a String method. It is used to return a new string in which a specified string is inserted at a specified index position in the current string instance. Syntax: public string Insert(int Indexvalue, string value) Explanation: Indexvalue: It is the index position of current string ...
[ { "code": null, "e": 25547, "s": 25519, "text": "\n31 Jan, 2019" }, { "code": null, "e": 25726, "s": 25547, "text": "In C#, Insert() method is a String method. It is used to return a new string in which a specified string is inserted at a specified index position in the current s...
Maximize Sum possible from an Array by the given moves - GeeksforGeeks
07 May, 2021 Given three integers N, M and K and an array a[] consisting of N integers, where M and K denotes the total number of possible moves and the number of possible moves(shift by an index) on the left of the current element in an array respectively, the task is to maximize the sum possible by traversing the arr...
[ { "code": null, "e": 26041, "s": 26013, "text": "\n07 May, 2021" }, { "code": null, "e": 26386, "s": 26041, "text": "Given three integers N, M and K and an array a[] consisting of N integers, where M and K denotes the total number of possible moves and the number of possible move...
Handling Ajax request in Django - GeeksforGeeks
06 May, 2022 This tutorial explains how to carry out an ajax request in the Django web framework. We will create a simple post-liking app as a part of the example. Glossary Project Initialization Create models Create views Write URLs Carry out a request with Jquery Ajax. Register models to admin and add some posts. I...
[ { "code": null, "e": 25703, "s": 25675, "text": "\n06 May, 2022" }, { "code": null, "e": 25856, "s": 25705, "text": "This tutorial explains how to carry out an ajax request in the Django web framework. We will create a simple post-liking app as a part of the example." }, { ...
D3.js zoom.interpolate() Function - GeeksforGeeks
25 Oct, 2020 The zoom.interpolate() function in D3.js library is used to set the interpolation factory for zoom transitions to the specified function. To apply direct interpolation between two views, try d3.interpolate instead. Syntax: zoom.interpolate([interpolate]) Parameters: This function accepts a single paramet...
[ { "code": null, "e": 26545, "s": 26517, "text": "\n25 Oct, 2020" }, { "code": null, "e": 26760, "s": 26545, "text": "The zoom.interpolate() function in D3.js library is used to set the interpolation factory for zoom transitions to the specified function. To apply direct interpola...
Ruby Integer even? function with example - GeeksforGeeks
24 Jun, 2020 The even? function in Ruby returns a boolean value. It returns true if the number is even, else it returns false. Syntax: number.even? Parameter: The function takes the integer which is to be checked for even or not. Return Value: The function returns a boolean value which determines if the value is even o...
[ { "code": null, "e": 25217, "s": 25189, "text": "\n24 Jun, 2020" }, { "code": null, "e": 25331, "s": 25217, "text": "The even? function in Ruby returns a boolean value. It returns true if the number is even, else it returns false." }, { "code": null, "e": 25352, "...
getent command in Linux with examples - GeeksforGeeks
20 May, 2019 getent is a Linux command that helps the user to get the entries in a number of important text files called databases. This includes the passwd and the group of databases which stores the user information. Hence getent is a common way to look up in user details on Linux. Since getent uses the same name of ...
[ { "code": null, "e": 25651, "s": 25623, "text": "\n20 May, 2019" }, { "code": null, "e": 26297, "s": 25651, "text": "getent is a Linux command that helps the user to get the entries in a number of important text files called databases. This includes the passwd and the group of da...
Boolean toString() method in Java with examples - GeeksforGeeks
03 Mar, 2021 The toString() method of Boolean class is a built in method to return the boolean value in string format. There are 2 overloads of toString() methods in Boolean class of Java: Syntax Boolean.toString(boolean value) Parameter: It takes a boolean value as input which is to be converted to string. Return Type...
[ { "code": null, "e": 24384, "s": 24356, "text": "\n03 Mar, 2021" }, { "code": null, "e": 24490, "s": 24384, "text": "The toString() method of Boolean class is a built in method to return the boolean value in string format." }, { "code": null, "e": 24560, "s": 2449...
XGBoost: theory and practice. Understand how one of the most popular... | by Arthur Mello | Towards Data Science
XGBoost stands for eXtreme Gradient Boosting and it’s an open-source implementation of the gradient boosted trees algorithm. It has been one of the most popular machine learning techniques in Kaggle competitions, due to its prediction power and ease of use. It is a supervised learning algorithm that can be used for reg...
[ { "code": null, "e": 400, "s": 47, "text": "XGBoost stands for eXtreme Gradient Boosting and it’s an open-source implementation of the gradient boosted trees algorithm. It has been one of the most popular machine learning techniques in Kaggle competitions, due to its prediction power and ease of use...
Simple Text Summarization in Python | by Andrew Udell | Towards Data Science
Project Gutenberg offers over 60,000 full length books. Wikipedia contains over 55 million unique articles. Wattpad has over 400 million short stories. In the age of the internet, there is no shortage of literature to read. These numbers, however, are completely overwhelming. A person could spend a lifetime attempting ...
[ { "code": null, "e": 396, "s": 172, "text": "Project Gutenberg offers over 60,000 full length books. Wikipedia contains over 55 million unique articles. Wattpad has over 400 million short stories. In the age of the internet, there is no shortage of literature to read." }, { "code": null, ...
Custom Object Detection using Darknet | Towards Data Science
In this article you will get your hands dirty using Darknet and training the model for mask detection. This article can be referred to train any custom object detector Citations: The video output feed is available on YouTube by Bloomberg Quicktake, images downloaded for training are available as open source on Kaggle. ...
[ { "code": null, "e": 274, "s": 171, "text": "In this article you will get your hands dirty using Darknet and training the model for mask detection." }, { "code": null, "e": 339, "s": 274, "text": "This article can be referred to train any custom object detector" }, { "cod...
Predicting House Prices with Linear Regression | Machine Learning from Scratch (Part II) | by Venelin Valkov | Towards Data Science
TL;DR Use a test-driven approach to build a Linear Regression model using Python from scratch. You will use your trained model to predict house sale prices and extend it to a multivariate Linear Regression. Smart Discounts with Logistic RegressionPredicting House Prices with Linear RegressionBuilding a Decision Tree fr...
[ { "code": null, "e": 378, "s": 171, "text": "TL;DR Use a test-driven approach to build a Linear Regression model using Python from scratch. You will use your trained model to predict house sale prices and extend it to a multivariate Linear Regression." }, { "code": null, "e": 814, "s...
How to maximize JFrame in Java Swing
To maximize JFrame in Java Swing, use the following − JFrame.MAXIMIZED_BOTH The following is an example to maximize JFrame in Java − package my; import javax.swing.JFrame; import javax.swing.JPanel; public class SwingDemo extends JFrame { JPanel panel = new JPanel(); public SwingDemo() { setVisible(true); ...
[ { "code": null, "e": 1116, "s": 1062, "text": "To maximize JFrame in Java Swing, use the following −" }, { "code": null, "e": 1138, "s": 1116, "text": "JFrame.MAXIMIZED_BOTH" }, { "code": null, "e": 1195, "s": 1138, "text": "The following is an example to maxi...
The @Deprecated Annotation in Java - GeeksforGeeks
23 Jun, 2021 The @Deprecated annotation tells the compiler that a method, class, or field is deprecated and that it should generate a warning if someone tries to use it. That’s what a deprecated class or method is. It’s no longer relevant. It is so unimportant that you should stop using it because it has been supersede...
[ { "code": null, "e": 23948, "s": 23920, "text": "\n23 Jun, 2021" }, { "code": null, "e": 24294, "s": 23948, "text": "The @Deprecated annotation tells the compiler that a method, class, or field is deprecated and that it should generate a warning if someone tries to use it. That’s...
How to align nested form rows using Bootstrap 4? - GeeksforGeeks
26 Nov, 2020 Bootstrap is a CSS framework used to design web pages. Bootstrap along with HTML and JavaScript results in interactive web designs. The most recent release is Bootstrap v4.5. Bootstrap has a variety of components and utilities. The Bootstrap components include the form component. Bootstrap has an inbuilt f...
[ { "code": null, "e": 25618, "s": 25590, "text": "\n26 Nov, 2020" }, { "code": null, "e": 26188, "s": 25618, "text": "Bootstrap is a CSS framework used to design web pages. Bootstrap along with HTML and JavaScript results in interactive web designs. The most recent release is Boot...
Exploring Well Log Data Using the Welly Python Library | by Andy McDonald | Towards Data Science
The welly library was developed by Agile Geoscience to help with loading, processing, and analysing well log data from a single well or multiple wells. The library allows exploration of the metadata found within the headers of las files and also contains a plotting function to display a typical well log. Additionally, ...
[ { "code": null, "e": 450, "s": 47, "text": "The welly library was developed by Agile Geoscience to help with loading, processing, and analysing well log data from a single well or multiple wells. The library allows exploration of the metadata found within the headers of las files and also contains a...
Program to check whether we can pick up and drop every passenger in given list in Python
Suppose we have a matrix called requested_trips where each row containing [start_x, end_x, num_passengers], and we also have a capacity value. Now each requested trip asks to pick up num_passengers passenger at start_x and drop them off at end_x. We also have a car with the capacity that is given, and start at position...
[ { "code": null, "e": 1521, "s": 1062, "text": "Suppose we have a matrix called requested_trips where each row containing [start_x, end_x, num_passengers], and we also have a capacity value. Now each requested trip asks to pick up num_passengers passenger at start_x and drop them off at end_x. We als...
Web scraping for financial statements with Python — 1 | by (Joe) Cho Hang Ng | Towards Data Science
There are not many data science use cases for accounting. However, accounting jobs are one of the tedious categories that need to be automated. One of the tasks I used to do is to get financial statements for individual companies so that I can analyze their performance against the industry. Basically, I would search th...
[ { "code": null, "e": 559, "s": 172, "text": "There are not many data science use cases for accounting. However, accounting jobs are one of the tedious categories that need to be automated. One of the tasks I used to do is to get financial statements for individual companies so that I can analyze the...
How to find the number of digits in a given number using Python?
In this program, we have to find the number of digits in an integer given by the user. User Input: 123, Output: 3 User Input: 1987, Output: 4 Step 1: Take Integer value as input value from the userStep 2: Divide the number by 10 and convert the quotient into Integer typeStep 3: If quotient is not 0, update count of dig...
[ { "code": null, "e": 1149, "s": 1062, "text": "In this program, we have to find the number of digits in an integer given by the user." }, { "code": null, "e": 1176, "s": 1149, "text": "User Input: 123, Output: 3" }, { "code": null, "e": 1204, "s": 1176, "text"...
F# - if/else statement
An if/then statement can be followed by an optional else statement, which executes when the Boolean expression is false. The syntax of an if/then/else statement in F# programming language is − if expr then expr else expr let a : int32 = 100 (* check the boolean condition using if statement *) if (a < 20) then ...
[ { "code": null, "e": 2282, "s": 2161, "text": "An if/then statement can be followed by an optional else statement, which executes when the Boolean expression is false." }, { "code": null, "e": 2354, "s": 2282, "text": "The syntax of an if/then/else statement in F# programming lan...
ExpressJS - Routing
Web frameworks provide resources such as HTML pages, scripts, images, etc. at different routes. The following function is used to define routes in an Express application − This METHOD can be applied to any one of the HTTP verbs – get, set, put, delete. An alternate method also exists, which executes independent of the ...
[ { "code": null, "e": 2157, "s": 2061, "text": "Web frameworks provide resources such as HTML pages, scripts, images, etc. at different routes." }, { "code": null, "e": 2233, "s": 2157, "text": "The following function is used to define routes in an Express application −" }, { ...
Batch Script - Adding to the Registry
Adding to the registry is done via the REG ADD command. Note that in order to add values to the registry you need to have sufficient privileges on the system to perform this operation. The REG ADD command has the following variations. In the second variation, no name is specified for the key and it will add the name of...
[ { "code": null, "e": 2354, "s": 2169, "text": "Adding to the registry is done via the REG ADD command. Note that in order to add values to the registry you need to have sufficient privileges on the system to perform this operation." }, { "code": null, "e": 2515, "s": 2354, "text"...
ES6 - Math sqrt() Function
This method returns the square root of a number. If the value of a number is negative, sqrt returns NaN. Math.sqrt ( x ); x − represents a number Returns the square root of the number. console.log("---Math.sqrt()---") console.log("Math.sqrt(16) : "+Math.sqrt(16) console.log("Math.sqrt(15.5) : "+Math.sqrt(15.5)) ...
[ { "code": null, "e": 2382, "s": 2277, "text": "This method returns the square root of a number. If the value of a number is negative, sqrt returns NaN." }, { "code": null, "e": 2402, "s": 2382, "text": "Math.sqrt ( x ); \n" }, { "code": null, "e": 2426, "s": 2402...
How to copy files from one folder to another using Python?
The shutil module provides functions for copying files, as well as entire folders. For copying multiple files at once, you'll have to have a list of all files you want to copy and loop over them to copy them. Calling shutil.copy(source, destination) will copy the file at the path source to the folder at the path destin...
[ { "code": null, "e": 1271, "s": 1062, "text": "The shutil module provides functions for copying files, as well as entire folders. For copying multiple files at once, you'll have to have a list of all files you want to copy and loop over them to copy them." }, { "code": null, "e": 1578, ...
Matplotlib Histograms
A histogram is a graph showing frequency distributions. It is a graph showing the number of observations within each given interval. Example: Say you ask for the height of 250 people, you might end up with a histogram like this: You can read from the histogram that there are approximately: 2 people from 140 to 145c...
[ { "code": null, "e": 56, "s": 0, "text": "A histogram is a graph showing frequency distributions." }, { "code": null, "e": 133, "s": 56, "text": "It is a graph showing the number of observations within each given interval." }, { "code": null, "e": 230, "s": 133, ...
Tryit Editor v3.7
Tryit: HTML introduction
[]
Area of a Triangle from the given lengths of medians - GeeksforGeeks
01 Feb, 2022 Given three integers A,B and C which denotes length of the three medians of a triangle, the task is to calculate the area of the triangle. A median of a triangle is a line segment joining a vertex to the midpoint of the opposite side, thus bisecting that side. Examples: Input: A = 9, B = 12, C = 15 Output:...
[ { "code": null, "e": 24963, "s": 24935, "text": "\n01 Feb, 2022" }, { "code": null, "e": 25102, "s": 24963, "text": "Given three integers A,B and C which denotes length of the three medians of a triangle, the task is to calculate the area of the triangle." }, { "code": nu...
Using Kafka as a Temporary Data Store and Data-loss Prevention Tool in The Data Lake | by Lucio Daza | Towards Data Science
Apache Kafka is a streaming platform that allows for the creation of real-time data processing pipelines and streaming applications. Kafka is an excellent tool for a range of use cases. If you are interested in examples of how Kafka can be used for a web application’s metrics collection, read my previous article. Kafka...
[ { "code": null, "e": 486, "s": 171, "text": "Apache Kafka is a streaming platform that allows for the creation of real-time data processing pipelines and streaming applications. Kafka is an excellent tool for a range of use cases. If you are interested in examples of how Kafka can be used for a web ...
Data Science Tip #005: Two Correct Ways to Perform One-Hot Encoding! | by David Hundley | Towards Data Science
Hello, hello everybody! I hope you all are enjoying a nice Labor Day weekend. I personally took Friday off as well to extend my weekend into four days, and I had a lot of great quality time with my daughters these last few days. But you know me, I’m always itching to keep producing in some capacity! Before we get into ...
[ { "code": null, "e": 472, "s": 171, "text": "Hello, hello everybody! I hope you all are enjoying a nice Labor Day weekend. I personally took Friday off as well to extend my weekend into four days, and I had a lot of great quality time with my daughters these last few days. But you know me, I’m alway...
Hazelcast - Serialization
Hazelcast is ideally used in an environment where data/query are distributed across machines. This requires data to be serialized from our Java objects to a byte array which can be transferred over the network. Hazelcast supports various types of Serialization. However, let’s look at some commonly used ones, i.e., Java...
[ { "code": null, "e": 2174, "s": 1963, "text": "Hazelcast is ideally used in an environment where data/query are distributed across machines. This requires data to be serialized from our Java objects to a byte array which can be transferred over the network." }, { "code": null, "e": 2323,...
Arduino - infinite loop
It is the loop having no terminating condition, so the loop becomes infinite. for (;;) { // statement block } while(1) { // statement block } do { Block of statements; } while(1); 65 Lectures 6.5 hours Amit Rana 43 Lectures 3 hours Amit Rana 20 Lectures 2 hours Ash...
[ { "code": null, "e": 2948, "s": 2870, "text": "It is the loop having no terminating condition, so the loop becomes infinite." }, { "code": null, "e": 2984, "s": 2948, "text": "for (;;) {\n // statement block\n}\n" }, { "code": null, "e": 3020, "s": 2984, "te...
How to do that animated ‘race’ bar chart | by Keith McNulty | Towards Data Science
In this article, we are going to analyze the all time performance of English football teams since their leagues began in 1888, and use that data to create an animated bar chart that cycles through each year and shows the total points accrued of the top ten teams throughout history. We will also use the title bar to pro...
[ { "code": null, "e": 620, "s": 172, "text": "In this article, we are going to analyze the all time performance of English football teams since their leagues began in 1888, and use that data to create an animated bar chart that cycles through each year and shows the total points accrued of the top te...
Python Tkinter - MessageBox Widget - GeeksforGeeks
26 Mar, 2020 Python offers multiple options for developing GUI (Graphical User Interface). Out of all the GUI methods, tkinter is the most commonly used method. It is a standard Python interface to the Tk GUI toolkit shipped with Python. Python with tkinter is the fastest and easiest way to create the GUI applications....
[ { "code": null, "e": 42677, "s": 42649, "text": "\n26 Mar, 2020" }, { "code": null, "e": 43031, "s": 42677, "text": "Python offers multiple options for developing GUI (Graphical User Interface). Out of all the GUI methods, tkinter is the most commonly used method. It is a standar...
C program to find permutations of given strings
Suppose we have few strings in an array. We shall have to find all permutations of them in different line. So, if the input is like strings = ["abc", "def", "ghi"], then the output will be abc def ghi abc ghi def def abc ghi def ghi abc ghi abc def ghi def abc To solve this, we will follow these steps − Define a functi...
[ { "code": null, "e": 1169, "s": 1062, "text": "Suppose we have few strings in an array. We shall have to find all permutations of them in different line." }, { "code": null, "e": 1251, "s": 1169, "text": "So, if the input is like strings = [\"abc\", \"def\", \"ghi\"], then the ou...
SQL - CONCAT Function
SQL CONCAT function is used to concatenate two strings to form a single string. Try out the following example − SQL> SELECT CONCAT('FIRST ', 'SECOND'); +----------------------------+ | CONCAT('FIRST ', 'SECOND') | +----------------------------+ | FIRST SECOND | +----------------------------+ 1 row in set...
[ { "code": null, "e": 2566, "s": 2453, "text": "SQL CONCAT function is used to concatenate two strings to form a single string. Try out the following example −" }, { "code": null, "e": 2785, "s": 2566, "text": "SQL> SELECT CONCAT('FIRST ', 'SECOND');\n+---------------------------...
What are the differences between “untyped” & “dynamically typed” programming languages?
Dynamically typed language is called so because the type is associated with run-time values. You don’t have to specify types every time. As the name suggests, variables' types are dynamic, means even after you set a variable to a type you can change it. Some dynamically typed languages include Python, Perl, Ruby, etc. ...
[ { "code": null, "e": 1316, "s": 1062, "text": "Dynamically typed language is called so because the type is associated with run-time values. You don’t have to specify types every time. As the name suggests, variables' types are dynamic, means even after you set a variable to a type you can change it....
VBScript WeekDay Function
The WeekDay function returns an integer from 1 to 7 that represents the day of the week for the specified date. Weekday(date[,firstdayofweek]) Date, a Required Parameter. The Week day would be returns for this specified date. Date, a Required Parameter. The Week day would be returns for this specified date. firstday...
[ { "code": null, "e": 2192, "s": 2080, "text": "The WeekDay function returns an integer from 1 to 7 that represents the day of the week for the specified date." }, { "code": null, "e": 2226, "s": 2192, "text": "Weekday(date[,firstdayofweek]) \n" }, { "code": null, "e"...
How to Import and Export Datasets in Google Colab | by Mohammad Masum, PhD | Towards Data Science
Google Colaboratory, known as Colab, is a free Jupyter Notebook environment with many pre-installed libraries like Tensorflow, Pytorch, Keras, OpenCV, and many more. It is one of the cloud services that support GPU and TPU for free. Importing a dataset and training models on the data in the Colab facilitate the coding ...
[ { "code": null, "e": 621, "s": 172, "text": "Google Colaboratory, known as Colab, is a free Jupyter Notebook environment with many pre-installed libraries like Tensorflow, Pytorch, Keras, OpenCV, and many more. It is one of the cloud services that support GPU and TPU for free. Importing a dataset an...
Find Circles in an Image using OpenCV in Python
The OpenCV platform provides cv2 library for python. This can be used for various shape analysis which is useful in computer vision. In this article we will identify the shape of a circle using Open CV. For that we will use the cv2.HoughCircles() function.Finds circles in a grayscale image using the Hough transform. In...
[ { "code": null, "e": 1528, "s": 1062, "text": "The OpenCV platform provides cv2 library for python. This can be used for various shape analysis which is useful in computer vision. In this article we will identify the shape of a circle using Open CV. For that we will use the cv2.HoughCircles() functi...
LeetCode Problem 1 (Two Sum) Solution in Python | Towards Data Science
LeetCode is a platform that gives access to thousands of programming problems and helps users enhance their skills and get prepared for technical interviews that are usually part of the recruitment process for Engineering and ML positions. In today’s short guide we will explore the first problem called Two Sum and atte...
[ { "code": null, "e": 411, "s": 171, "text": "LeetCode is a platform that gives access to thousands of programming problems and helps users enhance their skills and get prepared for technical interviews that are usually part of the recruitment process for Engineering and ML positions." }, { "...
PHP mysqli_prepare() Function
The mysqli_prepare() function prepares an SQL statement for execution, you can use parameter markers ("?") in this query, specify values for them, and execute it later. mysqli_prepare($con, $str); con(Mandatory) This is an object representing a connection to MySQL Server. str(Mandatory) This is string value specifying...
[ { "code": null, "e": 2926, "s": 2757, "text": "The mysqli_prepare() function prepares an SQL statement for execution, you can use parameter markers (\"?\") in this query, specify values for them, and execute it later." }, { "code": null, "e": 2955, "s": 2926, "text": "mysqli_prep...
Tryit Editor v3.7
Tryit: Individual border sides
[]
RLIKE operator in MySQL - GeeksforGeeks
16 Dec, 2020 RLIKE :This operator in MySQL is used to performs a pattern match of a string expression against a pattern. Syntax : RLIKE pattern Parameters :This method accepts one parameter as mentioned in syntax. pattern –The pattern which we want to match against an expression. Various pattern and their usage are de...
[ { "code": null, "e": 24214, "s": 24186, "text": "\n16 Dec, 2020" }, { "code": null, "e": 24322, "s": 24214, "text": "RLIKE :This operator in MySQL is used to performs a pattern match of a string expression against a pattern." }, { "code": null, "e": 24331, "s": 24...
Build An Image Search Engine Using Python | Towards Data Science
We use search engine regularly. When we have queries, we can use the search engine like Google to retrieve the most relevant answer. Most of the queries format is text-based. But not most of the time, the text is quite useful to find relevant answers. For example, you want to search for a product on the internet, in th...
[ { "code": null, "e": 305, "s": 172, "text": "We use search engine regularly. When we have queries, we can use the search engine like Google to retrieve the most relevant answer." }, { "code": null, "e": 424, "s": 305, "text": "Most of the queries format is text-based. But not mos...
Power Set | Practice | GeeksforGeeks
Given a string S find all possible subsequences of the string in lexicographically-sorted order. Example 1: Input : str = "abc" Output: a ab abc ac b bc c Explanation : There are 7 substrings that can be formed from abc. Example 2: Input: str = "aa" Output: a a aa Explanation : There are 3 substrings that can be for...
[ { "code": null, "e": 335, "s": 238, "text": "Given a string S find all possible subsequences of the string in lexicographically-sorted order." }, { "code": null, "e": 346, "s": 335, "text": "Example 1:" }, { "code": null, "e": 461, "s": 346, "text": "Input : s...
Bootstrap nav-stacked class
Use the nav-stacked class to set the pills vertically. Set the pills vertically using the class .nav-stacked along with the classes: .nav, .nav-pills. You can try to run the following code to set vertical pills in Bootstrap − Live Demo <!DOCTYPE html> <html> <head> <title>Bootstrap Example</title> <link ...
[ { "code": null, "e": 1213, "s": 1062, "text": "Use the nav-stacked class to set the pills vertically. Set the pills vertically using the class .nav-stacked along with the classes: .nav, .nav-pills." }, { "code": null, "e": 1288, "s": 1213, "text": "You can try to run the followin...
JavaScript | JSON Arrays - GeeksforGeeks
28 May, 2021 The JSON Arrays is similar to JavaScript Arrays. Syntax of Arrays in JSON Objects: // JSON Arrays Syntax { "name":"Peter parker", "heroName": "Spiderman", "friends" : ["Deadpool", "Hulk", "Wolverine"] } Accessing Array Values: The Array values can be accessed using the index of each element ...
[ { "code": null, "e": 25352, "s": 25324, "text": "\n28 May, 2021" }, { "code": null, "e": 25402, "s": 25352, "text": "The JSON Arrays is similar to JavaScript Arrays. " }, { "code": null, "e": 25437, "s": 25402, "text": "Syntax of Arrays in JSON Objects: " },...
Function Overloading
When we have multiple functions with the same name but different parameters, then they are said to be overloaded. This technique is used to enhance the readability of the program. There are two ways to overload a function, i.e. − Having different number of arguments Having different argument types Function overloading ...
[ { "code": null, "e": 2001, "s": 1821, "text": "When we have multiple functions with the same name but different parameters, then they are said to be overloaded. This technique is used to enhance the readability of the program." }, { "code": null, "e": 2051, "s": 2001, "text": "Th...
Comprehensions and Generator Expression in Python | by Iffat Malik Gore | Towards Data Science
To understand Python’s Comprehension capabilities, it’s important to understand the concept of comprehension at first. Comprehension in programming is nothing but writing the (existing) code in a short and concise manner, mostly one single line. It is constructing a new sequence by shortening the existing one. Being go...
[ { "code": null, "e": 683, "s": 172, "text": "To understand Python’s Comprehension capabilities, it’s important to understand the concept of comprehension at first. Comprehension in programming is nothing but writing the (existing) code in a short and concise manner, mostly one single line. It is con...
How to make a plot title partially bold using ggplot2 in R?
To make a plot title partially bold using ggplot2, we can use bquote function inside labs function and then changing the default font to bold using bold function as shown in the below examples. While using these functions we need to make sure that the title that we want to bold should be inside circular brackets approp...
[ { "code": null, "e": 1391, "s": 1062, "text": "To make a plot title partially bold using ggplot2, we can use bquote function inside labs function and then changing the default font to bold using bold function as shown in the below examples. While using these functions we need to make sure that the t...
How to create a plot in base R with tick marks of larger size?
To create a plot in base R with tick marks of larger size, we can make use of axis function tck argument. The tck argument value will decide the size of the tick mark but since the ticks lie below the plot area hence the value will have a negative associated with it. Therefore, it will be like -0.05. Check out the belo...
[ { "code": null, "e": 1421, "s": 1062, "text": "To create a plot in base R with tick marks of larger size, we can make use of axis function tck argument. The tck argument value will decide the size of the tick mark but since the ticks lie below the plot area hence the value will have a negative assoc...
A/B testing with probabilistic programming and PyMC3 (part I) | by Tung T. Nguyen | Towards Data Science
Disclaimer: This article is strongly influenced by the book Probabilistic-Programming-and-Bayesian-Methods-for-Hackers. Our main contribution is, perhaps, the expository style-which we hope will benefit the beginners to either probabilistic programming or A/B testing or maybe both. We will also reflect on some of our e...
[ { "code": null, "e": 569, "s": 172, "text": "Disclaimer: This article is strongly influenced by the book Probabilistic-Programming-and-Bayesian-Methods-for-Hackers. Our main contribution is, perhaps, the expository style-which we hope will benefit the beginners to either probabilistic programming or...
Text-To-Speech changing voice in Python
18 Oct, 2019 There are several APIs available to convert text to speech in python. One such APIs is the Python Text to Speech API commonly known as the pyttsx3 API. pyttsx3 is a very easy to use tool which converts the text entered, into audio. Installation To install the pyttsx3 API, open terminal and write pip instal...
[ { "code": null, "e": 52, "s": 24, "text": "\n18 Oct, 2019" }, { "code": null, "e": 284, "s": 52, "text": "There are several APIs available to convert text to speech in python. One such APIs is the Python Text to Speech API commonly known as the pyttsx3 API. pyttsx3 is a very easy...
Convert user input string into regular expression using JavaScript
04 Jun, 2020 Regular expressions (RegExp) are patterns used to match character combinations in strings. In JavaScript, regular expressions are also objects. There are two ways to construct a regular expression in JavaScript . 1. Using a regular expression literal, which consists of a pattern enclosed between slashes, a...
[ { "code": null, "e": 28, "s": 0, "text": "\n04 Jun, 2020" }, { "code": null, "e": 241, "s": 28, "text": "Regular expressions (RegExp) are patterns used to match character combinations in strings. In JavaScript, regular expressions are also objects. There are two ways to construct...
Merge Sort for Doubly Linked List
03 Jul, 2022 Given a doubly linked list, write a function to sort the doubly linked list in increasing order using merge sort.For example the following doubly linked list should be changed to {2, 4, 8, 10}. Merge sort for singly linked list is already discussed. The important change here is to modify the previous point...
[ { "code": null, "e": 54, "s": 26, "text": "\n03 Jul, 2022" }, { "code": null, "e": 248, "s": 54, "text": "Given a doubly linked list, write a function to sort the doubly linked list in increasing order using merge sort.For example the following doubly linked list should be change...
Program to find GCD or HCF of two numbers using Middle School Procedure
28 Sep, 2021 Given two positive integers M and N, the task is to find the greatest common divisor (GCD) using Middle School Procedure. Note: GCD of two integers is the largest positive integer that divides both of the integers. Examples: Input: m = 12, n = 14 Output: 2 Prime factor of 12 = 1*2*2*3 Prime factor of 14...
[ { "code": null, "e": 53, "s": 25, "text": "\n28 Sep, 2021" }, { "code": null, "e": 280, "s": 53, "text": "Given two positive integers M and N, the task is to find the greatest common divisor (GCD) using Middle School Procedure. Note: GCD of two integers is the largest positive in...
Find permutation array from the cumulative sum array
01 Mar, 2022 Given an array arr[] of N elements where each arr[i] is the cumulative sum of the subarray P[0...i] of another array P[] where P is the permutation of the integers from 1 to N. The task is to find the array P[], if no such P exists then print -1.Examples: Input: arr[] = {2, 3, 6} Output: 2 1 3Input: arr[...
[ { "code": null, "e": 28, "s": 0, "text": "\n01 Mar, 2022" }, { "code": null, "e": 286, "s": 28, "text": "Given an array arr[] of N elements where each arr[i] is the cumulative sum of the subarray P[0...i] of another array P[] where P is the permutation of the integers from 1 to N...
Output of Java Programs | Set 33 (Collections)
18 Sep, 2017 Prerequisite: Java – Collections 1. What is the output of following Java Program? import java.util.ArrayList;class Demo {public void show() { ArrayList<Integer> list = new ArrayList<Integer>(); list.add(4); list.add(7); list.add(1); for (int number : list) { ...
[ { "code": null, "e": 52, "s": 24, "text": "\n18 Sep, 2017" }, { "code": null, "e": 85, "s": 52, "text": "Prerequisite: Java – Collections" }, { "code": null, "e": 134, "s": 85, "text": "1. What is the output of following Java Program?" }, { "code": "im...
What is the best way in C to convert a number to a string?
02 Jun, 2017 #include<stdio.h>int main(){ char result[50]; float num = 23.34; sprintf(result, "%f", num); printf("\n The string for the num is %s", result); getchar();} You can also write your own function using ASCII values of numbers. C-Data Types c-puzzle C Language Writing code in comment? Please use...
[ { "code": null, "e": 52, "s": 24, "text": "\n02 Jun, 2017" }, { "code": "#include<stdio.h>int main(){ char result[50]; float num = 23.34; sprintf(result, \"%f\", num); printf(\"\\n The string for the num is %s\", result); getchar();}", "e": 223, "s": 52, "text": nu...
Range Class | Guava | Java
02 Jun, 2018 Guava’s Range represents an interval, for example, a < range < b. Here range includes any value between a and b, called endpoints which form the boundary. Any value between the boundary is a contiguous span of values of type Comparable. Declaration : The declaration for com.google.common.collect.Range<C> c...
[ { "code": null, "e": 28, "s": 0, "text": "\n02 Jun, 2018" }, { "code": null, "e": 265, "s": 28, "text": "Guava’s Range represents an interval, for example, a < range < b. Here range includes any value between a and b, called endpoints which form the boundary. Any value between th...
Check if a column starts with given string in Pandas DataFrame? - GeeksforGeeks
01 Aug, 2020 In this program, we are trying to check whether the specified column in the given data frame starts with specified string or not. Let us try to understand this using an example suppose we have a dataset named student_id, date_of_joining, branch. Example: Python3 #importing library pandas as pdimport pandas...
[ { "code": null, "e": 24525, "s": 24497, "text": "\n01 Aug, 2020" }, { "code": null, "e": 24780, "s": 24525, "text": "In this program, we are trying to check whether the specified column in the given data frame starts with specified string or not. Let us try to understand this usi...
Django - Sending E-mails
Django comes with a ready and easy-to-use light engine to send e-mail. Similar to Python you just need an import of smtplib. In Django you just need to import django.core.mail. To start sending e-mail, edit your project settings.py file and set the following options − EMAIL_HOST − smtp server. EMAIL_HOST − smtp server....
[ { "code": null, "e": 2314, "s": 2045, "text": "Django comes with a ready and easy-to-use light engine to send e-mail. Similar to Python you just need an import of smtplib. In Django you just need to import django.core.mail. To start sending e-mail, edit your project settings.py file and set the foll...
Data Structure and Algorithms Selection Sort
Selection sort is a simple sorting algorithm. This sorting algorithm is an in-place comparison-based algorithm in which the list is divided into two parts, the sorted part at the left end and the unsorted part at the right end. Initially, the sorted part is empty and the unsorted part is the entire list. The smallest e...
[ { "code": null, "e": 2886, "s": 2580, "text": "Selection sort is a simple sorting algorithm. This sorting algorithm is an in-place comparison-based algorithm in which the list is divided into two parts, the sorted part at the left end and the unsorted part at the right end. Initially, the sorted par...
How to calculate Years between Dates in R ? - GeeksforGeeks
14 May, 2021 In this article, we will discuss how to calculate the number of years or difference of years between two dates in R programming language. Example: Input: Date_1 = 2020/02/21 Date_2 = 2023/03/21 Output: 3 Explanation: In Date_1 and Date_2 have three years difference in year. Here we will use seq() functio...
[ { "code": null, "e": 26487, "s": 26459, "text": "\n14 May, 2021" }, { "code": null, "e": 26625, "s": 26487, "text": "In this article, we will discuss how to calculate the number of years or difference of years between two dates in R programming language." }, { "code": nul...
CSS Syntax and Selectors - GeeksforGeeks
11 Oct, 2021 A CSS Syntax rule consists of a selector, property, and its value. The selector points to the HTML element where CSS style is to be applied. The CSS property is separated by semicolons. It is a combination of selector name followed by the property: value pair that is defined for the specific selector. Syn...
[ { "code": null, "e": 27991, "s": 27963, "text": "\n11 Oct, 2021" }, { "code": null, "e": 28295, "s": 27991, "text": "A CSS Syntax rule consists of a selector, property, and its value. The selector points to the HTML element where CSS style is to be applied. The CSS property is se...
Python | os.times() method - GeeksforGeeks
18 Jun, 2019 OS module in Python provides functions for interacting with the operating system. OS comes under Python’s standard utility modules. This module provides a portable way of using operating system dependent functionality. os.times() method in Python is used to get the current global process times. Syntax: os....
[ { "code": null, "e": 25665, "s": 25637, "text": "\n18 Jun, 2019" }, { "code": null, "e": 25884, "s": 25665, "text": "OS module in Python provides functions for interacting with the operating system. OS comes under Python’s standard utility modules. This module provides a portable...
Ultimate Walkthrough for ML-Agents in Unity3D | by Sebastian Schuchmann | Towards Data Science
Hey! This will be a fast-paced, complete walkthrough of building an A.I. with Unity’s ML-Agents. Like a good TV Chef, I already have a simple game prepared, which you can clone from GitHub. Make sure you do, if you want to follow along! 🙂 Repository: A.I. Jumping Cars Currently, it’s just a human-controlled game, no m...
[ { "code": null, "e": 411, "s": 172, "text": "Hey! This will be a fast-paced, complete walkthrough of building an A.I. with Unity’s ML-Agents. Like a good TV Chef, I already have a simple game prepared, which you can clone from GitHub. Make sure you do, if you want to follow along! 🙂" }, { "...
WebAssembly - Convert WAT to WASM
In the previous chapter, we have seen how to write code in .wat i.e., WebAssembly text format. The WebAssembly text format will not directly work inside the browser and you need to convert it into binary format i.e., WASM to work inside browser. Let us convert .WAT to .WASM. The code we are going to use is as follows −...
[ { "code": null, "e": 2479, "s": 2233, "text": "In the previous chapter, we have seen how to write code in .wat i.e., WebAssembly text format. The WebAssembly text format will not directly work inside the browser and you need to convert it into binary format i.e., WASM to work inside browser." }, ...
Earn Money with Machine Learning by Deploying an API | by Garrett Eichhorn | Towards Data Science
If you’re reading this, it’s because you’ve created some valuable code that you’re hoping to publish. Whether you simply packaged together some open-source technology or built a brilliant new algorithm, there’s a good chance that other technologists will find your solution useful. In this article, you’ll leverage open-...
[ { "code": null, "e": 328, "s": 46, "text": "If you’re reading this, it’s because you’ve created some valuable code that you’re hoping to publish. Whether you simply packaged together some open-source technology or built a brilliant new algorithm, there’s a good chance that other technologists will f...
How do I return multiple results in a MySQL subquery with IN()?
In MySQL, you can easily return multiple results, but also achieve this with subquery using IN(). Let us first create a table − mysql> create table DemoTable1317 -> ( -> Id int NOT NULL AUTO_INCREMENT PRIMARY KEY, -> Name varchar(20) -> ); Query OK, 0 rows affected (0.49 sec) Insert some records in the table using inse...
[ { "code": null, "e": 1190, "s": 1062, "text": "In MySQL, you can easily return multiple results, but also achieve this with subquery using IN(). Let us first create a table −" }, { "code": null, "e": 1339, "s": 1190, "text": "mysql> create table DemoTable1317\n-> (\n-> Id int NOT...
What is constructor overloading in Java?
Similar to methods you can also overload constructors i.e. you can write more than constructor with different parameters. And, based on the parameters we pass at the time of instantiation, respective constructor will be invoked. Live Demo public class Sample { public Sample() { System.out.println("Hello how a...
[ { "code": null, "e": 1184, "s": 1062, "text": "Similar to methods you can also overload constructors i.e. you can write more than constructor with different parameters." }, { "code": null, "e": 1291, "s": 1184, "text": "And, based on the parameters we pass at the time of instanti...
Count distinct value in MongoDB?
Use the concept of length to count distinct value. Following is the syntax − db.yourCollectionName.distinct("yourFieldName").length; Let us create a collection with documents − > db.countDistinctDemo.insertOne({"StudentName":"John"}); { "acknowledged" : true, "insertedId" : ObjectId("5cbd6166de8cc557214c0dfa") } ...
[ { "code": null, "e": 1139, "s": 1062, "text": "Use the concept of length to count distinct value. Following is the syntax −" }, { "code": null, "e": 1195, "s": 1139, "text": "db.yourCollectionName.distinct(\"yourFieldName\").length;" }, { "code": null, "e": 1239, ...
Display Timestamp before the current date in MySQL
Let us first create a table − mysql> create table DemoTable( ArrivalDate timestamp ); Query OK, 0 rows affected (1.96 sec) Insert some records in the table using insert command − mysql> insert into DemoTable values('2019-09-14 17:25:00'); Query OK, 1 row affected (0.26 sec) mysql> insert into DemoTable values('2019-...
[ { "code": null, "e": 1092, "s": 1062, "text": "Let us first create a table −" }, { "code": null, "e": 1188, "s": 1092, "text": "mysql> create table DemoTable(\n ArrivalDate timestamp\n);\nQuery OK, 0 rows affected (1.96 sec)" }, { "code": null, "e": 1244, "s": 1...
Union and Union All in MS SQL Server - GeeksforGeeks
14 Aug, 2020 1. Union :Union means joining two or more data sets into a single set. In SQL Server, Union is used to combine two queries into a single result set using the select statements. Union extracts all the rows that are described in the query. Syntax – query1 UNION query2 Union holds a few conditions before bein...
[ { "code": null, "e": 23502, "s": 23474, "text": "\n14 Aug, 2020" }, { "code": null, "e": 23740, "s": 23502, "text": "1. Union :Union means joining two or more data sets into a single set. In SQL Server, Union is used to combine two queries into a single result set using the selec...
SAP ABAP - Macros
If we want to reuse the same set of statements more than once in a program, we need to include them in a macro. For example, a macro can be useful for long calculations or for writing complex WRITE statements. We can only use a macro within a program in which it is defined. Macro definition should occur before the macr...
[ { "code": null, "e": 3244, "s": 2898, "text": "If we want to reuse the same set of statements more than once in a program, we need to include them in a macro. For example, a macro can be useful for long calculations or for writing complex WRITE statements. We can only use a macro within a program in...
Integers and Floating-Point Numbers
In any programming language, there are two basic building blocks of arithmetic and computation. They are integers and floating-point values. Built-in representation of the values of integers and floating-point are called numeric primitives. On the other hand, their representation as immediate values in code are called ...
[ { "code": null, "e": 2416, "s": 2078, "text": "In any programming language, there are two basic building blocks of arithmetic and computation. They are integers and floating-point values. Built-in representation of the values of integers and floating-point are called numeric primitives. On the other...
Bokeh - Plots with Glyphs
Any plot is usually made up of one or many geometrical shapes such as line, circle, rectangle, etc. These shapes have visual information about the corresponding set of data. In Bokeh terminology, these geometrical shapes are called gylphs. Bokeh plots constructed using bokeh.plotting interface use a default set of tool...
[ { "code": null, "e": 2684, "s": 2270, "text": "Any plot is usually made up of one or many geometrical shapes such as line, circle, rectangle, etc. These shapes have visual information about the corresponding set of data. In Bokeh terminology, these geometrical shapes are called gylphs. Bokeh plots c...
How to Run MySQL Using Docker. Run MySQL with less effort | by Mahbub Zaman | Towards Data Science
If you’re a database administrator, data scientist, or developer, you may have to use MySQL to store and manipulate data. Since Docker has become a popular DevOps tool in recent years, you will eventually need to know how to run MySQL inside a Docker container. Running your application on a different machine can be ner...
[ { "code": null, "e": 434, "s": 172, "text": "If you’re a database administrator, data scientist, or developer, you may have to use MySQL to store and manipulate data. Since Docker has become a popular DevOps tool in recent years, you will eventually need to know how to run MySQL inside a Docker cont...
Working with DateTime in Python. Become a master of dates and times in... | by Sarah Beshr | Towards Data Science
Throughout your career as a data scientist, it’s inevitable that you’ll come across data containing date and time. For this reason, this extensive guide is here to help make manipulating date and time data using Python’s datetime module a breeze. We’ll cover a range of topics such as handling date and time strings, mea...
[ { "code": null, "e": 555, "s": 172, "text": "Throughout your career as a data scientist, it’s inevitable that you’ll come across data containing date and time. For this reason, this extensive guide is here to help make manipulating date and time data using Python’s datetime module a breeze. We’ll co...
Detect Change Points with Bayesian Inference and PyMC3 | by Khuyen Tran | Towards Data Science
Imagine you use Google Analytics to track the views of your website. After looking at the views, you suspect there might be a sudden change in the number of views after a certain date. If there is indeed a date when the number of views changes suddenly, how do you find that date? Wouldn’t it be nice if you can leverage...
[ { "code": null, "e": 357, "s": 172, "text": "Imagine you use Google Analytics to track the views of your website. After looking at the views, you suspect there might be a sudden change in the number of views after a certain date." }, { "code": null, "e": 453, "s": 357, "text": "I...
Hibernate groupby criteria and HQL query Example
PROGRAMMINGJava ExamplesC Examples Java Examples C Examples C Tutorials aws JAVAEXCEPTIONSCOLLECTIONSSWINGJDBC EXCEPTIONS COLLECTIONS SWING JDBC JAVA 8 SPRING SPRING BOOT HIBERNATE PYTHON PHP JQUERY PROGRAMMINGJava ExamplesC Examples Java Examples C Examples C Tutorials aws Here I m going to show how to read the data f...
[ { "code": null, "e": 158, "s": 123, "text": "PROGRAMMINGJava ExamplesC Examples" }, { "code": null, "e": 172, "s": 158, "text": "Java Examples" }, { "code": null, "e": 183, "s": 172, "text": "C Examples" }, { "code": null, "e": 195, "s": 183, ...
MySQL Stored Procedure to update records with certain condition?
For this, you can use the UPDATE command along with the WHERE clause in a PROCEDURE. Let us first create a table − mysql> create table DemoTable -> ( -> Id int, -> FirstName varchar(20), -> LastName varchar(20) -> ); Query OK, 0 rows affected (0.56 sec) Insert some records in the table using insert comma...
[ { "code": null, "e": 1177, "s": 1062, "text": "For this, you can use the UPDATE command along with the WHERE clause in a PROCEDURE. Let us first create a table −" }, { "code": null, "e": 1331, "s": 1177, "text": "mysql> create table DemoTable\n -> (\n -> Id int,\n -> FirstN...
Databases 101: How to Choose a Python Database Library | by Sara A. Metwalli | Towards Data Science
You can’t spell data science without data. Data is the most important part of data science. I can argue that all the field — and subfields — of data science is the science of interpreting what the data got to say. It’s the art of telling a story through your data. Collecting, cleaning, and analyzing data are three of t...
[ { "code": null, "e": 311, "s": 46, "text": "You can’t spell data science without data. Data is the most important part of data science. I can argue that all the field — and subfields — of data science is the science of interpreting what the data got to say. It’s the art of telling a story through yo...
Java Program to Check if a Given Number is Perfect Number - GeeksforGeeks
04 Dec, 2020 A number is said to be a perfect number if the sum of its proper divisors ( i.e. all positive divisors excluding the number itself )is equal to that number itself. Aliquot sum is the sum of divisors of a number, excluding the number itself. Hence, a number is a perfect number only if it is equal to its ali...
[ { "code": null, "e": 23582, "s": 23554, "text": "\n04 Dec, 2020" }, { "code": null, "e": 23936, "s": 23582, "text": "A number is said to be a perfect number if the sum of its proper divisors ( i.e. all positive divisors excluding the number itself )is equal to that number itself....
XQuery - replace function
The replace function replaces the matched input string with a given string. replace($input, $regex, $string) $input − input string. $input − input string. $regex − regular expression. $regex − regular expression. $string - string to replace original string. $string - string to replace original string. let $input := '...
[ { "code": null, "e": 1948, "s": 1872, "text": "The replace function replaces the matched input string with a given string." }, { "code": null, "e": 1981, "s": 1948, "text": "replace($input, $regex, $string)" }, { "code": null, "e": 2004, "s": 1981, "text": "$i...
Java Program to Convert a Decimal Number to Binary Number using Stacks - GeeksforGeeks
07 Jan, 2021 Java is high level, compiled as well as interpreted programming language. Stack is an abstract data type used in most of the programming languages and can be implemented using arrays or linked list. Stack data structure follows the principle of LIFO (Last In First Out) . Stack allows push, pop, peek operat...
[ { "code": null, "e": 25249, "s": 25221, "text": "\n07 Jan, 2021" }, { "code": null, "e": 25996, "s": 25249, "text": "Java is high level, compiled as well as interpreted programming language. Stack is an abstract data type used in most of the programming languages and can be imple...
Angle between a Pair of Lines in 3D - GeeksforGeeks
02 Feb, 2022 Given coordinates of three points A(x1, y1, z1), B(x2, y2, z2), and C(x3, y3, z3) in a 3D plane, where B is the intersection point of line AB and BC, the task is to find the angle between lines AB and BC. Examples: Input: x1 = 1, y1 = 3, z1 = 3; x2 = 3, y2 = 4, z2 = 5; x3 = 5, y3 = 6, z3 = 9; Output: 54...
[ { "code": null, "e": 26561, "s": 26533, "text": "\n02 Feb, 2022" }, { "code": null, "e": 26767, "s": 26561, "text": "Given coordinates of three points A(x1, y1, z1), B(x2, y2, z2), and C(x3, y3, z3) in a 3D plane, where B is the intersection point of line AB and BC, the task is t...
Digital Image Processing Algorithms using MATLAB - GeeksforGeeks
23 Feb, 2021 Like it is said, “One picture is worth more than ten thousand words “A digital image is composed of thousands and thousands of pixels. An image could also be defined as a two-dimensional function, f(x, y), where x and y are spatial (plane) coordinates and therefore the amplitude of f at any pair of coordin...
[ { "code": null, "e": 25517, "s": 25489, "text": "\n23 Feb, 2021" }, { "code": null, "e": 25652, "s": 25517, "text": "Like it is said, “One picture is worth more than ten thousand words “A digital image is composed of thousands and thousands of pixels." }, { "code": null, ...
SeekBar in Kotlin - GeeksforGeeks
28 Mar, 2022 Android seekBar is a modified version of progressBar that have draggable thumb in which a user can drag the thumb back and forth to set current progress value. We can use seekbar in our android device like Brightness control, volume control etc. It is one of the important user Interface element which provi...
[ { "code": null, "e": 25263, "s": 25235, "text": "\n28 Mar, 2022" }, { "code": null, "e": 25509, "s": 25263, "text": "Android seekBar is a modified version of progressBar that have draggable thumb in which a user can drag the thumb back and forth to set current progress value. We ...
How to manipulate the pixel values of an image using Python ? - GeeksforGeeks
28 Apr, 2021 It is well known that a color image is a collection of various pixels. And if we change the pixel value the image will turn into an image of a different color. Doing this tedious task manually is awful as an image might contain millions of pixels. So we will write a Python script that will easily complete ...
[ { "code": null, "e": 25537, "s": 25509, "text": "\n28 Apr, 2021" }, { "code": null, "e": 25855, "s": 25537, "text": "It is well known that a color image is a collection of various pixels. And if we change the pixel value the image will turn into an image of a different color. Doi...
Python | time.process_time_ns() method - GeeksforGeeks
17 Sep, 2019 Time module in Python provides various time-related functions. This module comes under Python’s standard utility modules. time.process_time_ns() method of time module in Python is used to get the sum of the system and user CPU time of the current process in nanoseconds. This method does not include time el...
[ { "code": null, "e": 25481, "s": 25453, "text": "\n17 Sep, 2019" }, { "code": null, "e": 25603, "s": 25481, "text": "Time module in Python provides various time-related functions. This module comes under Python’s standard utility modules." }, { "code": null, "e": 2596...
Vector of Unordered Maps in C++ with Examples - GeeksforGeeks
29 Nov, 2021 Vector: Vector: It is the same as dynamic arrays with the ability to resize itself automatically when an element is inserted or deleted, with their storage being handled automatically by the container. Vector elements are placed in contiguous storage so that they can be accessed and traversed using iterato...
[ { "code": null, "e": 25343, "s": 25315, "text": "\n29 Nov, 2021" }, { "code": null, "e": 25351, "s": 25343, "text": "Vector:" }, { "code": null, "e": 25654, "s": 25351, "text": "Vector: It is the same as dynamic arrays with the ability to resize itself automat...
Python | Split a list into sublists of given lengths - GeeksforGeeks
03 Apr, 2019 The problem of splitting a list into sublists is quite generic but to split in sublist of given length is not so common. Given a list of lists and list of length, the task is to split the list into sublists of given length. Example: Input : Input = [1, 2, 3, 4, 5, 6, 7] length_to_split = [2, 1, 3, ...
[ { "code": null, "e": 26227, "s": 26199, "text": "\n03 Apr, 2019" }, { "code": null, "e": 26451, "s": 26227, "text": "The problem of splitting a list into sublists is quite generic but to split in sublist of given length is not so common. Given a list of lists and list of length, ...
Pattern Drawing in R - GeeksforGeeks
03 Mar, 2021 Everyone found an easy way for pattern printing in other programming languages. But its a tough task using R language . This article focuses on drawing various patterns using R language and its constructs. Approach Start first loop for number of lines Start second loop for item to be displayed Print item I...
[ { "code": null, "e": 26487, "s": 26459, "text": "\n03 Mar, 2021" }, { "code": null, "e": 26693, "s": 26487, "text": "Everyone found an easy way for pattern printing in other programming languages. But its a tough task using R language . This article focuses on drawing various pat...
How to Force User to Change Password at Next Login in Linux - GeeksforGeeks
23 Aug, 2021 For security reasons, you must frequently change the password of accounts on the system. In this article, we are going to see how can we force the user to change the password on the next login in Linux. We can do that by two methods one is using passwd command and the other is by using chage command. To fo...
[ { "code": null, "e": 25675, "s": 25647, "text": "\n23 Aug, 2021" }, { "code": null, "e": 25977, "s": 25675, "text": "For security reasons, you must frequently change the password of accounts on the system. In this article, we are going to see how can we force the user to change t...
How to Remove Special Character from String in PHP ? - GeeksforGeeks
02 Dec, 2021 In this article, we will see how to remove special characters from strings in PHP, along with understanding their implementation through the examples. We have given a string and we need to remove special characters from string str in PHP, for this, we have the following methods in PHP: Using str_replace() ...
[ { "code": null, "e": 32651, "s": 32623, "text": "\n02 Dec, 2021" }, { "code": null, "e": 32938, "s": 32651, "text": "In this article, we will see how to remove special characters from strings in PHP, along with understanding their implementation through the examples. We have give...
How to compute mod of a big number? - GeeksforGeeks
09 Dec, 2021 Given a big number ‘num’ represented as string and an integer x, find value of “num % x” or “num mod x”. Output is expected as an integer. Examples : Input: num = "12316767678678", a = 10 Output: num (mod a) ≡ 8 The idea is to process all digits one by one and use the property that xy (mod a) ≡ ((x (mo...
[ { "code": null, "e": 25897, "s": 25869, "text": "\n09 Dec, 2021" }, { "code": null, "e": 26036, "s": 25897, "text": "Given a big number ‘num’ represented as string and an integer x, find value of “num % x” or “num mod x”. Output is expected as an integer." }, { "code": nu...
Program to find Nth term in the series 0, 0, 2, 1, 4, 2, 6, 3, 8,... - GeeksforGeeks
25 Feb, 2021 Given a number N. The task is to write a program to find the N-th term in the below series: 0, 0, 2, 1, 4, 2, 6, 3, 8, 4, 10, 5, 12, 6, 14, 7, 16, 8,..... Examples: Input : N = 10 Output : 4 Input : N = 7 Output : 6 On observing carefully, you will find that the series is a mixture of 2 series: Ter...
[ { "code": null, "e": 26612, "s": 26584, "text": "\n25 Feb, 2021" }, { "code": null, "e": 26706, "s": 26612, "text": "Given a number N. The task is to write a program to find the N-th term in the below series: " }, { "code": null, "e": 26769, "s": 26706, "text...
Data Wrangling With Pandas. My journey into data science has been... | by Mohammed Raza | Towards Data Science
My journey into data science has been possible by the vast resources of the internet. The Journal of Data Science defines it as almost everything that has something to do with data. In a job, this translates to using data to have an impact on the organization by adding value. Most commonly it is to use and apply the da...
[ { "code": null, "e": 737, "s": 172, "text": "My journey into data science has been possible by the vast resources of the internet. The Journal of Data Science defines it as almost everything that has something to do with data. In a job, this translates to using data to have an impact on the organiza...