title stringlengths 3 221 | text stringlengths 17 477k | parsed listlengths 0 3.17k |
|---|---|---|
Improving the Stack Overflow search algorithm using Semantic Search and NLP | by Rohit Agrawal | Towards Data Science | If you a person who has ever tried to write a piece of code, you are sure to come across Stack Overflow (it’s that famous). For those who live under a rock, Stack Overflow provides one of the largest QA platforms for programmers. Users post questions/doubts and their fellow peers try to provide solutions in the most he... | [
{
"code": null,
"e": 608,
"s": 172,
"text": "If you a person who has ever tried to write a piece of code, you are sure to come across Stack Overflow (it’s that famous). For those who live under a rock, Stack Overflow provides one of the largest QA platforms for programmers. Users post questions/doub... |
Bye-bye Python. Hello Julia!. As Python’s lifetime grinds to a halt... | by Ari Joury | Towards Data Science | Don’t get me wrong. Python’s popularity is still backed by a rock-solid community of computer scientists, data scientists and AI specialists.
But if you’ve ever been at a dinner table with these people, you also know how much they rant about the weaknesses of Python. From being slow to requiring excessive testing, to p... | [
{
"code": null,
"e": 313,
"s": 171,
"text": "Don’t get me wrong. Python’s popularity is still backed by a rock-solid community of computer scientists, data scientists and AI specialists."
},
{
"code": null,
"e": 578,
"s": 313,
"text": "But if you’ve ever been at a dinner table wi... |
OpenCV - Adaptive Threshold | In simple thresholding, the threshold value is global, i.e., it is same for all the pixels in the image. Adaptive thresholding is the method where the threshold value is calculated for smaller regions and therefore, there will be different threshold values for different regions.
In OpenCV, you can perform Adaptive thre... | [
{
"code": null,
"e": 3284,
"s": 3004,
"text": "In simple thresholding, the threshold value is global, i.e., it is same for all the pixels in the image. Adaptive thresholding is the method where the threshold value is calculated for smaller regions and therefore, there will be different threshold val... |
Convert string to char array in Java | The following is our string.
String str = "Tutorial";
Now, use the toCharArray() method to convert string to char array.
char[] ch = str.toCharArray();
Now let us see the complete example.
Live Demo
public class Demo {
public static void main(String []args) {
String str = "Tutorial";
System.out.println(... | [
{
"code": null,
"e": 1091,
"s": 1062,
"text": "The following is our string."
},
{
"code": null,
"e": 1116,
"s": 1091,
"text": "String str = \"Tutorial\";"
},
{
"code": null,
"e": 1183,
"s": 1116,
"text": "Now, use the toCharArray() method to convert string to ... |
JavaFX - 2D Shapes Path Element Line | The path element line is used to draw a straight line to a point in the specified coordinates from the current position.
It is represented by a class named LineTo. This class belongs to the package javafx.scene.shape.
This class has 2 properties of the double datatype namely −
X − The x coordinate of the point to which... | [
{
"code": null,
"e": 2021,
"s": 1900,
"text": "The path element line is used to draw a straight line to a point in the specified coordinates from the current position."
},
{
"code": null,
"e": 2118,
"s": 2021,
"text": "It is represented by a class named LineTo. This class belongs... |
Kubernetes Application Deployment with AWS EKS and ECR | by Janitha Tennakoon | Towards Data Science | Kubernetes is a container orchestration platform that is created by Google in 2014. It is an open-source platform where currently many organizations widely use for container deployment and management. Although there are other container orchestration tools are available in the community like Docker Swarm, Kubernetes rem... | [
{
"code": null,
"e": 580,
"s": 172,
"text": "Kubernetes is a container orchestration platform that is created by Google in 2014. It is an open-source platform where currently many organizations widely use for container deployment and management. Although there are other container orchestration tools... |
Word2Vec Implementation. How to implement Word2Vec using numpy... | by Rahuljha | Towards Data Science | This article is about the implementation of a very popular word embedding technique known as Word2Vec. It was implemented by Tomas Mikolov at Google.
Objective
Introduction
Core idea
Architecture
Data preparation
Model training
Model inference and analysis
The objective of this article to show the inner workings of Wor... | [
{
"code": null,
"e": 322,
"s": 172,
"text": "This article is about the implementation of a very popular word embedding technique known as Word2Vec. It was implemented by Tomas Mikolov at Google."
},
{
"code": null,
"e": 332,
"s": 322,
"text": "Objective"
},
{
"code": null... |
C - Preprocessors | The C Preprocessor is not a part of the compiler, but is a separate step in the compilation process. In simple terms, a C Preprocessor is just a text substitution tool and it instructs the compiler to do required pre-processing before the actual compilation. We'll refer to the C Preprocessor as CPP.
All preprocessor co... | [
{
"code": null,
"e": 2385,
"s": 2084,
"text": "The C Preprocessor is not a part of the compiler, but is a separate step in the compilation process. In simple terms, a C Preprocessor is just a text substitution tool and it instructs the compiler to do required pre-processing before the actual compila... |
Part 3: Time Series Chains. A New Approach to Time Series... | by Sean Law | Towards Data Science | STUMPY is a powerful and scalable Python library for modern time series analysis and, at its core, efficiently computes something called a matrix profile. The goal of this multi-part series is to explain what the matrix profile is and how you can start leveraging STUMPY for all of your modern time series data mining ta... | [
{
"code": null,
"e": 497,
"s": 172,
"text": "STUMPY is a powerful and scalable Python library for modern time series analysis and, at its core, efficiently computes something called a matrix profile. The goal of this multi-part series is to explain what the matrix profile is and how you can start le... |
How to detect the Internet connection is offline or not using JavaScript? - GeeksforGeeks | 28 Jan, 2020
In some cases, it is necessary to determine whether the browser is online or offline before performing a required task. Many developers use AJAX to determine the connection status of the browser (online or offline) by sending a request to the server. However, this is not a good method for determining the s... | [
{
"code": null,
"e": 25967,
"s": 25939,
"text": "\n28 Jan, 2020"
},
{
"code": null,
"e": 26355,
"s": 25967,
"text": "In some cases, it is necessary to determine whether the browser is online or offline before performing a required task. Many developers use AJAX to determine the c... |
CSS Buttons - Pushy Buttons Usage | Pushy Buttons library is a small CSS Pressable Buttons library.
To load the pushy-buttons.min.css library, download the css from github and paste the following line in the <head> section of the webpage.
<head>
<link rel = "stylesheet" href = "pushy-buttons.min.css">
</head>
Create a button using html button tag and... | [
{
"code": null,
"e": 1962,
"s": 1898,
"text": "Pushy Buttons library is a small CSS Pressable Buttons library."
},
{
"code": null,
"e": 2101,
"s": 1962,
"text": "To load the pushy-buttons.min.css library, download the css from github and paste the following line in the <head> sec... |
Check if a large number is divisible by 3 or not in C++ | Here we will see how to check a number is divisible by 3 or not. In this case the number is very large number. So we put the number as string.
A number will be divisible by 3, if the sum of digits is divisible by 3.
Live Demo
#include <bits/stdc++.h>
using namespace std;
bool isDiv3(string num){
int n = num.length(... | [
{
"code": null,
"e": 1205,
"s": 1062,
"text": "Here we will see how to check a number is divisible by 3 or not. In this case the number is very large number. So we put the number as string."
},
{
"code": null,
"e": 1278,
"s": 1205,
"text": "A number will be divisible by 3, if the... |
C++ Program to Implement Stack in STL | Stack is a linear data structure which follows a particular order in which the operations are performed. The order may be FILO (First In first out) or LIFO (Last In First Out)
Begin
Declare stack vector.
Take the input as per choice.
Call the functions within switch operation:
s.size() = Returns the size of... | [
{
"code": null,
"e": 1238,
"s": 1062,
"text": "Stack is a linear data structure which follows a particular order in which the operations are performed. The order may be FILO (First In first out) or LIFO (Last In First Out)"
},
{
"code": null,
"e": 1570,
"s": 1238,
"text": "Begin\... |
Encapsulation in C++ - GeeksforGeeks | 24 Nov, 2021
In normal terms Encapsulation is defined as wrapping up of data and information under a single unit. In Object Oriented Programming, Encapsulation is defined as binding together the data and the functions that manipulates them.Consider a real life example of encapsulation, in a company there are different ... | [
{
"code": null,
"e": 26960,
"s": 26932,
"text": "\n24 Nov, 2021"
},
{
"code": null,
"e": 28047,
"s": 26960,
"text": "In normal terms Encapsulation is defined as wrapping up of data and information under a single unit. In Object Oriented Programming, Encapsulation is defined as bi... |
Program to find GCD or HCF of two numbers - GeeksforGeeks | 03 Feb, 2022
GCD (Greatest Common Divisor) or HCF (Highest Common Factor) of two numbers is the largest number that divides both of them.
For example GCD of 20 and 28 is 4 and GCD of 98 and 56 is 14. For solution suppose a=98 & b=56
a>b so put a= a-b and b is remain same so a=98-56=42 & b= 56 . Now b>a so b=b... | [
{
"code": null,
"e": 24550,
"s": 24522,
"text": "\n03 Feb, 2022"
},
{
"code": null,
"e": 24676,
"s": 24550,
"text": "GCD (Greatest Common Divisor) or HCF (Highest Common Factor) of two numbers is the largest number that divides both of them. "
},
{
"code": null,
"e": ... |
How to Get First Column of Pandas DataFrame? - GeeksforGeeks | 28 Nov, 2021
In this article, we will discuss how to get the first column of the pandas dataframe in Python programming language.
This function is used to get the first column using slice operator. for the rows we extract all of them, for columns specify the index for first column.
Syntax :
dataframe.iloc[:, 0]
where. ... | [
{
"code": null,
"e": 25555,
"s": 25527,
"text": "\n28 Nov, 2021"
},
{
"code": null,
"e": 25672,
"s": 25555,
"text": "In this article, we will discuss how to get the first column of the pandas dataframe in Python programming language."
},
{
"code": null,
"e": 25825,
... |
PyCairo- Drawing Function curve - GeeksforGeeks | 23 Jan, 2022
In this article we will learn how we can draw a simple function curve using PyCairo in python. n mathematics, the graph of a function f is the set of ordered pairs, where f(x) = y. In the common case where x and f(x) are real numbers, these pairs are Cartesian coordinates of points in two-dimensional space... | [
{
"code": null,
"e": 25665,
"s": 25637,
"text": "\n23 Jan, 2022"
},
{
"code": null,
"e": 25974,
"s": 25665,
"text": "In this article we will learn how we can draw a simple function curve using PyCairo in python. n mathematics, the graph of a function f is the set of ordered pairs... |
Most frequent word in an array of strings | Practice | GeeksforGeeks | Given an array arr containing N words consisting of lowercase characters. Your task is to find the most frequent word in the array. If multiple words have same frequency, then print the word whose first occurence occurs last in the array as compared to the other strings with same frequency.
Example 1:
Input:
N = 3
arr[... | [
{
"code": null,
"e": 530,
"s": 238,
"text": "Given an array arr containing N words consisting of lowercase characters. Your task is to find the most frequent word in the array. If multiple words have same frequency, then print the word whose first occurence occurs last in the array as compared to th... |
What is use of $error variable in PowerShell? | Error variable in PowerShell is to view the errors generated in the current PowerShell session. We can say that the $Error variable is the container that stores all the errors and the latest error will be displayed first. For the example below, we will set the $Errorview to Category view to minimizing the error display... | [
{
"code": null,
"e": 1432,
"s": 1062,
"text": "Error variable in PowerShell is to view the errors generated in the current PowerShell session. We can say that the $Error variable is the container that stores all the errors and the latest error will be displayed first. For the example below, we will ... |
Convert a number to a string in JavaScript - GeeksforGeeks | 05 Mar, 2021
In JavaScript, you can change any number into string format using the following methods.
1. Using toString(): This method belongs to the Number.Prototype object. It takes an integer or a floating-point number and converts it into a string type.
Syntax:
num.toString();
Example:JavascriptJavascript<script> ... | [
{
"code": null,
"e": 37968,
"s": 37940,
"text": "\n05 Mar, 2021"
},
{
"code": null,
"e": 38057,
"s": 37968,
"text": "In JavaScript, you can change any number into string format using the following methods."
},
{
"code": null,
"e": 38213,
"s": 38057,
"text": "1... |
AutoCompleteTextView in Kotlin - GeeksforGeeks | 28 Mar, 2022
Android AutoCompleteTextView is an editable text view which shows a list of suggestions when user starts typing text. When a user starts typing, a dropdown menu will be there based on the entered characters, defined in the threshold limit and the user can choose an item from the list to replace the text.
T... | [
{
"code": null,
"e": 23992,
"s": 23964,
"text": "\n28 Mar, 2022"
},
{
"code": null,
"e": 24298,
"s": 23992,
"text": "Android AutoCompleteTextView is an editable text view which shows a list of suggestions when user starts typing text. When a user starts typing, a dropdown menu wi... |
Check whether a given number is Polydivisible or Not - GeeksforGeeks | 22 Feb, 2022
Given an integer n, find whether n is a Polydivisible or not. In mathematics, a number is called Polydivisible if it follows some unique properties. The number should not have any leading zeroes. The number formed by first i digits of the input number should be divisible by i, where . If any number follow ... | [
{
"code": null,
"e": 24716,
"s": 24688,
"text": "\n22 Feb, 2022"
},
{
"code": null,
"e": 25092,
"s": 24716,
"text": "Given an integer n, find whether n is a Polydivisible or not. In mathematics, a number is called Polydivisible if it follows some unique properties. The number sho... |
Functional programming for deep learning | by Joyce Xu | Towards Data Science | Before I started my most recent job at ThinkTopic, the concepts of “functional programming” and “machine learning” belonged to two different worlds entirely. One was a programming paradigm surging in popularity as the world turned towards simplicity, composability, and immutability to maintain complex scaling applicati... | [
{
"code": null,
"e": 600,
"s": 172,
"text": "Before I started my most recent job at ThinkTopic, the concepts of “functional programming” and “machine learning” belonged to two different worlds entirely. One was a programming paradigm surging in popularity as the world turned towards simplicity, comp... |
Create an Image Classification Web App using PyTorch and Streamlit | by Dehao Zhang | Towards Data Science | You just developed a cool ML model.
You are proud of it. You want to show it to your friends through a web demo so they can interact with your model and provide feedback.
However, you are not familiar with common frameworks such as Django and Flask.
You start to ask yourself: Is there a way to build a quick web demo wi... | [
{
"code": null,
"e": 207,
"s": 171,
"text": "You just developed a cool ML model."
},
{
"code": null,
"e": 342,
"s": 207,
"text": "You are proud of it. You want to show it to your friends through a web demo so they can interact with your model and provide feedback."
},
{
"... |
How to use ‘while loop’ in Java? | A while loop statement in Java programming language repeatedly executes a target statement as long as a given condition is true.
The syntax of a while loop is −
while(Boolean_expression) {
// Statements
}
Here, statement(s) may be a single statement or a block of statements. The condition may be any expression, and ... | [
{
"code": null,
"e": 1191,
"s": 1062,
"text": "A while loop statement in Java programming language repeatedly executes a target statement as long as a given condition is true."
},
{
"code": null,
"e": 1223,
"s": 1191,
"text": "The syntax of a while loop is −"
},
{
"code":... |
Managed Apache Airflow on AWS — New AWS Service For Data Pipelines | by Anna Geller | Towards Data Science | Apache Airflow has been initially released as an open-source product in 2015 [1]. Since its creation, it gained a lot of traction in the data engineering community due to its capability to develop data pipelines with Python, its extensibility, a wide range of operators, and an open-source community. Despite its popular... | [
{
"code": null,
"e": 589,
"s": 171,
"text": "Apache Airflow has been initially released as an open-source product in 2015 [1]. Since its creation, it gained a lot of traction in the data engineering community due to its capability to develop data pipelines with Python, its extensibility, a wide rang... |
Entering JSON data into MySQL? | Use the JSON data type to first set JSON data and then insert. Let us first create a table −
mysql> create table DemoTable1876
(
EmployeeInformation JSON
);
Query OK, 0 rows affected (0.00 sec)
Insert some records in the table using insert command −
mysql> insert into DemoTable1876 values('{
'> "EmployeeDat... | [
{
"code": null,
"e": 1155,
"s": 1062,
"text": "Use the JSON data type to first set JSON data and then insert. Let us first create a table −"
},
{
"code": null,
"e": 1265,
"s": 1155,
"text": "mysql> create table DemoTable1876\n (\n EmployeeInformation JSON\n );\nQuery OK, 0 ... |
Tooltips with Python’s Matplotlib | by Thiago Carvalho | Towards Data Science | Allowing the user to hover the mouse or click a part of our visualization to get more context is excellent. And tooltips are a perfect way to save space in our chart.
For example, for most scatter plots labelling every point can get tricky. You can color-code them and use a legend, but even that can get messy when ther... | [
{
"code": null,
"e": 339,
"s": 172,
"text": "Allowing the user to hover the mouse or click a part of our visualization to get more context is excellent. And tooltips are a perfect way to save space in our chart."
},
{
"code": null,
"e": 511,
"s": 339,
"text": "For example, for mo... |
Matplotlib.axes.Axes.get_lines() in Python - GeeksforGeeks | 27 Apr, 2020
Matplotlib is a library in Python and it is numerical – mathematical extension for NumPy library. The Axes Class contains most of the figure elements: Axis, Tick, Line2D, Text, Polygon, etc., and sets the coordinate system. And the instances of Axes supports callbacks through a callbacks attribute.
The Axe... | [
{
"code": null,
"e": 24876,
"s": 24848,
"text": "\n27 Apr, 2020"
},
{
"code": null,
"e": 25176,
"s": 24876,
"text": "Matplotlib is a library in Python and it is numerical – mathematical extension for NumPy library. The Axes Class contains most of the figure elements: Axis, Tick, ... |
MySQL query to count rows in multiple tables | Let us first create a table −
mysql> create table DemoTable1 (FirstName varchar(100));
Query OK, 0 rows affected (0.54 sec)
Insert some records in the table using insert command −
mysql> insert into DemoTable1 values('Bob');
Query OK, 1 row affected (0.20 sec)
mysql> insert into DemoTable1 values('James');
Query OK, 1 ... | [
{
"code": null,
"e": 1092,
"s": 1062,
"text": "Let us first create a table −"
},
{
"code": null,
"e": 1186,
"s": 1092,
"text": "mysql> create table DemoTable1 (FirstName varchar(100));\nQuery OK, 0 rows affected (0.54 sec)"
},
{
"code": null,
"e": 1242,
"s": 1186,... |
MPI - Distributed Computing made easy - GeeksforGeeks | 01 Apr, 2020
The Underlying Problem
To make things easier, let’s directly jump to some statistics:
Facebook, currently, has 1.5 billion active monthly users.
Google performs at least 1 trillion searches per year.
About 48 hours of video is uploaded in Youtube every minute.
With such a high demand, I do believe that a... | [
{
"code": null,
"e": 24538,
"s": 24510,
"text": "\n01 Apr, 2020"
},
{
"code": null,
"e": 24563,
"s": 24540,
"text": "The Underlying Problem"
},
{
"code": null,
"e": 24626,
"s": 24563,
"text": "To make things easier, let’s directly jump to some statistics:"
}... |
I want to resize and position a JFrame in Java. How can I achieve that? | To resize and position JFrame, use the Dimensions class. Here, we have set the bounds for the frame −
int width = 500;
int height = 400;
Dimension size = Toolkit.getDefaultToolkit().getScreenSize();
frame.setBounds((int) size.getWidth() - width, 0, width, height);
The following is an example to resize and poisiton a fr... | [
{
"code": null,
"e": 1164,
"s": 1062,
"text": "To resize and position JFrame, use the Dimensions class. Here, we have set the bounds for the frame −"
},
{
"code": null,
"e": 1327,
"s": 1164,
"text": "int width = 500;\nint height = 400;\nDimension size = Toolkit.getDefaultToolkit(... |
Tryit Editor v3.7 | Tryit: HTML aside element | [] |
JavaScript Tutorial | JavaScript is the world's most popular programming language.
JavaScript is the programming language of the Web.
JavaScript is easy to learn.
This tutorial will teach you JavaScript from basic to advanced.
With our "Try it Yourself" editor, you can edit the source code and view
the result.
Try it Yourself »
We recomm... | [
{
"code": null,
"e": 61,
"s": 0,
"text": "JavaScript is the world's most popular programming language."
},
{
"code": null,
"e": 112,
"s": 61,
"text": "JavaScript is the programming language of the Web."
},
{
"code": null,
"e": 141,
"s": 112,
"text": "JavaScrip... |
Difference between readObject and readResolve method in serialization | Serialization is the process of converting object to stream byte and storing byte stream in database or memory. Class which implements java.io.Serializable interface can be serialized.
Class which is implementing this interface gives the responsibility to JVM for serialize or persist java object
As per the oracle doc... | [
{
"code": null,
"e": 1248,
"s": 1062,
"text": "Serialization is the process of converting object to stream byte and storing byte stream in database or memory. Class which implements java.io.Serializable interface can be serialized. "
},
{
"code": null,
"e": 1361,
"s": 1248,
"text... |
ReactJS defaultProps - GeeksforGeeks | 26 Mar, 2021
The defaultProps is a React component property that allows you to set default values for the props argument. If the prop property is passed, it will be changed. The defaultProps can be defined as a property on the component class itself, to set the default props for the class.
Step 1: Create a React applic... | [
{
"code": null,
"e": 24037,
"s": 24009,
"text": "\n26 Mar, 2021"
},
{
"code": null,
"e": 24315,
"s": 24037,
"text": "The defaultProps is a React component property that allows you to set default values for the props argument. If the prop property is passed, it will be changed. Th... |
Power BI - Timeseries, Aggregation, and Filters - GeeksforGeeks | 18 Sep, 2020
Prerequisite: Power BI – Drilling Down and Up in Hierarchies
This article discusses the various important concepts of Power BI along with its implementation. The following concepts will be discussed here :
Time SeriesAggregationFilters
Time Series
Aggregation
Filters
Understanding the Dataset:The dataset u... | [
{
"code": null,
"e": 23953,
"s": 23925,
"text": "\n18 Sep, 2020"
},
{
"code": null,
"e": 24014,
"s": 23953,
"text": "Prerequisite: Power BI – Drilling Down and Up in Hierarchies"
},
{
"code": null,
"e": 24159,
"s": 24014,
"text": "This article discusses the va... |
Convert byte[] array to File using Java | 18 May, 2022
As we know whenever it comes to writing over a file, write() method of the File class comes into play but here we can not use it in order to convert that byte into a file. In order to convert a byte array to a file, we will be using a method named the getBytes() method of String class.
Implementation: Conv... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n18 May, 2022"
},
{
"code": null,
"e": 315,
"s": 28,
"text": "As we know whenever it comes to writing over a file, write() method of the File class comes into play but here we can not use it in order to convert that byte into a file. In ... |
Largest Sum Contiguous Subarray | 05 Jul, 2022
Write an efficient program to find the sum of the contiguous subarray within a one-dimensional array of numbers that has the largest sum.
Chapters
descriptions off, selected
captions settings, opens captions settings dialog
captions off, selected
English
This is a modal window.
Beginning of dialog windo... | [
{
"code": null,
"e": 54,
"s": 26,
"text": "\n05 Jul, 2022"
},
{
"code": null,
"e": 193,
"s": 54,
"text": "Write an efficient program to find the sum of the contiguous subarray within a one-dimensional array of numbers that has the largest sum. "
},
{
"code": null,
"e"... |
YearMonth format() method in Java | 04 Sep, 2021
The format() method of YearMonth class in Java is used to format this YearMonth instance according to a specified DateTimeFormatter for year-month passed as parameter to this method.
Syntax:
public String format(DateTimeFormatter formatter)
Parameter: This method accepts a single parameter formatter whic... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n04 Sep, 2021"
},
{
"code": null,
"e": 212,
"s": 28,
"text": "The format() method of YearMonth class in Java is used to format this YearMonth instance according to a specified DateTimeFormatter for year-month passed as parameter to this ... |
How to compare two NumPy arrays? | 03 Jun, 2022
Here we will be focusing on the comparison done using NumPy on arrays. Comparing two NumPy arrays determines whether they are equivalent by checking if every element at each corresponding index is the same.
Method 1: We generally use the == operator to compare two NumPy arrays to generate a new array obje... | [
{
"code": null,
"e": 53,
"s": 25,
"text": "\n03 Jun, 2022"
},
{
"code": null,
"e": 261,
"s": 53,
"text": "Here we will be focusing on the comparison done using NumPy on arrays. Comparing two NumPy arrays determines whether they are equivalent by checking if every element at each ... |
Lasso Regression in R Programming | 28 Sep, 2021
Lasso regression is a classification algorithm that uses shrinkage in simple and sparse models(i.e model with fewer parameters). In Shrinkage, data values are shrunk towards a central point like the mean. Lasso regression is a regularized regression algorithm that performs L1 regularization which adds pena... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n28 Sep, 2021"
},
{
"code": null,
"e": 401,
"s": 28,
"text": "Lasso regression is a classification algorithm that uses shrinkage in simple and sparse models(i.e model with fewer parameters). In Shrinkage, data values are shrunk towards a... |
Python3 – if , if..else, Nested if, if-elif statements | 11 Apr, 2022
There comes situations in real life when we need to do some specific task and based on some specific conditions and, we decide what should we do next. Similarly there comes a situation in programming where a specific task is to be performed if a specific condition is True. In such cases, conditional statem... | [
{
"code": null,
"e": 52,
"s": 24,
"text": "\n11 Apr, 2022"
},
{
"code": null,
"e": 443,
"s": 52,
"text": "There comes situations in real life when we need to do some specific task and based on some specific conditions and, we decide what should we do next. Similarly there comes a... |
vector shrink_to_fit() function in C++ STL | 09 Jun, 2022
The vector::shrink_to_fit() is a built-in function in C++ STL which reduces the capacity of the container to fit its size and destroys all elements beyond the capacity. Syntax:
vector_name.shrink_to_fit()
Parameters: The function does not accept any parameters. Return value: The function does not returns a... | [
{
"code": null,
"e": 53,
"s": 25,
"text": "\n09 Jun, 2022"
},
{
"code": null,
"e": 230,
"s": 53,
"text": "The vector::shrink_to_fit() is a built-in function in C++ STL which reduces the capacity of the container to fit its size and destroys all elements beyond the capacity. Synta... |
How to Add Google Maps to a Website ? | 12 Aug, 2021
The purpose of this article is to add Google Maps to a website. These are the following steps to add Google Maps to a website.
Generate an API KeyCreate the HTML Container of the mapAdd an external script by google inside the HTML documentWrite JavaScript code to bring the map inside that container.
Genera... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n12 Aug, 2021"
},
{
"code": null,
"e": 155,
"s": 28,
"text": "The purpose of this article is to add Google Maps to a website. These are the following steps to add Google Maps to a website."
},
{
"code": null,
"e": 329,
"s... |
Create a Numpy array filled with all ones | 21 Feb, 2022
In this article, we will learn how to create a Numpy array filled with all one, given the shape and type of array. We can use Numpy.ones() method to do this task. This method takes three parameters, discussed below –
shape : integer or sequence of integers
order : C_contiguous or F_contiguous
C... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n21 Feb, 2022"
},
{
"code": null,
"e": 247,
"s": 28,
"text": "In this article, we will learn how to create a Numpy array filled with all one, given the shape and type of array. We can use Numpy.ones() method to do this task. This method ... |
Modern Exploratory Data Analysis. Review of 4 libraries for automatic EDA | by ChiefHustler | Towards Data Science | EDA stands for Exploratory Data Analysis and is probably the most important yet most overlooked step in any data science project.
My goal is to share with you some tools that will instantly 10x your productivity when exploring data.
It’s during the exploration phase that the data scientists get close and intimate with ... | [
{
"code": null,
"e": 301,
"s": 171,
"text": "EDA stands for Exploratory Data Analysis and is probably the most important yet most overlooked step in any data science project."
},
{
"code": null,
"e": 404,
"s": 301,
"text": "My goal is to share with you some tools that will instan... |
Predicting Next Purchase Day. Machine Learning model to predict when... | by Barış Karaman | Towards Data Science | This series of articles was designed to explain how to use Python in a simplistic way to fuel your company’s growth by applying the predictive approach to all your actions. It will be a combination of programming, data analysis, and machine learning.
I will cover all the topics in the following nine articles:
1- Know Y... | [
{
"code": null,
"e": 422,
"s": 171,
"text": "This series of articles was designed to explain how to use Python in a simplistic way to fuel your company’s growth by applying the predictive approach to all your actions. It will be a combination of programming, data analysis, and machine learning."
}... |
Plotting Data on Google Map using pygmaps package? | Python pygmaps library provides a wrapper for the google maps javascript api. With this library python users can create a matplotlib like interface to generate the html and javascript and then can depicts all the additional information user’s would like to add on top of Google Maps.
We are only going to use the pygmaps... | [
{
"code": null,
"e": 1346,
"s": 1062,
"text": "Python pygmaps library provides a wrapper for the google maps javascript api. With this library python users can create a matplotlib like interface to generate the html and javascript and then can depicts all the additional information user’s would like... |
How can I generate random number in a given range in Android? | This example demonstrates how do I generate random number in a given range on android.
Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required details to create a new project.
Step 2 − Add the following code to res/layout/activity_main.xml.
<?xml version="1.0" encoding="utf-8"?>
... | [
{
"code": null,
"e": 1149,
"s": 1062,
"text": "This example demonstrates how do I generate random number in a given range on android."
},
{
"code": null,
"e": 1278,
"s": 1149,
"text": "Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required... |
JavaScript removeEventListener() method with examples | The JavaScript removeEventListener() method is used to remove an event listener from an element that has been previously attached with the addEventListener() method.
Following is the code for removeEventListener() method −
Live Demo
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport"... | [
{
"code": null,
"e": 1228,
"s": 1062,
"text": "The JavaScript removeEventListener() method is used to remove an event listener from an element that has been previously attached with the addEventListener() method."
},
{
"code": null,
"e": 1285,
"s": 1228,
"text": "Following is the... |
Excel’s CHOOSE Function with Array - GeeksforGeeks | 29 Oct, 2021
The Excel CHOOSE function returns a value/reference from an array using a given position.
Syntax:
=CHOOSE (index_num, value1, [value2], ...)
Arguments:
index_num: The value to choose.
value1: The first value from which to choose.
value2 [optional]: The second value from which to choose.
index_num: It is ... | [
{
"code": null,
"e": 25044,
"s": 25016,
"text": "\n29 Oct, 2021"
},
{
"code": null,
"e": 25134,
"s": 25044,
"text": "The Excel CHOOSE function returns a value/reference from an array using a given position."
},
{
"code": null,
"e": 25142,
"s": 25134,
"text": "... |
jQuery - Element Class Selector | The element class selector selects all the elements which match with the given class of the elements.
Here is the simple syntax to use this selector −
$('.classid')
Here is the description of all the parameters used by this selector −
classid − This is class ID available in the document.
classid − This is class ID ava... | [
{
"code": null,
"e": 2424,
"s": 2322,
"text": "The element class selector selects all the elements which match with the given class of the elements."
},
{
"code": null,
"e": 2473,
"s": 2424,
"text": "Here is the simple syntax to use this selector −"
},
{
"code": null,
... |
How to get local time and date in android using LocalDateTime API class? | This example demonstrate about How to get local time and date in android using LocalDateTime API class.
Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required details to create a new project.
Step 2 − Add the following code to res/layout/activity_main.xml.
<?xml version="1.0" en... | [
{
"code": null,
"e": 1166,
"s": 1062,
"text": "This example demonstrate about How to get local time and date in android using LocalDateTime API class."
},
{
"code": null,
"e": 1295,
"s": 1166,
"text": "Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and ... |
Probability of Knight to remain in the chessboard - GeeksforGeeks | 19 Apr, 2021
Given an NxN chessboard and a Knight at position (x,y). The Knight has to take exactly K steps, where at each step it chooses any of the 8 directions uniformly at random. What is the probability that the Knight remains in the chessboard after taking K steps, with the condition that it can’t enter the board... | [
{
"code": null,
"e": 25122,
"s": 25094,
"text": "\n19 Apr, 2021"
},
{
"code": null,
"e": 25465,
"s": 25122,
"text": "Given an NxN chessboard and a Knight at position (x,y). The Knight has to take exactly K steps, where at each step it chooses any of the 8 directions uniformly at ... |
How to support webview with multiple screens in android? | This example demonstrate about How to support webview with multiple screens in android.
Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required details to create a new project.
Step 2 − Add the following code to res/layout/activity_main.xml.
<?xml version = "1.0" encoding = "utf-... | [
{
"code": null,
"e": 1150,
"s": 1062,
"text": "This example demonstrate about How to support webview with multiple screens in android."
},
{
"code": null,
"e": 1279,
"s": 1150,
"text": "Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all require... |
Count of substrings of a Binary string containing only 1s - GeeksforGeeks | 30 Mar, 2022
Given a binary string of length N, we need to find out how many substrings of this string contain only 1s.
Examples:
Input: S = “0110111”Output: 9Explanation:There are 9 substring with only 1’s characters. “1” comes 5 times. “11” comes 3 times. “111” comes 1 time.
Input: S = “000”Output: 0
Approach: The i... | [
{
"code": null,
"e": 25014,
"s": 24986,
"text": "\n30 Mar, 2022"
},
{
"code": null,
"e": 25121,
"s": 25014,
"text": "Given a binary string of length N, we need to find out how many substrings of this string contain only 1s."
},
{
"code": null,
"e": 25132,
"s": 251... |
GATE | GATE-CS-2015 (Set 2) | Question 40 | 28 Jun, 2021
Consider six memory partitions of size 200 KB, 400 KB, 600 KB, 500 KB, 300 KB, and 250 KB, where KB refers to kilobyte. These partitions need to be allotted to four processes of sizes 357 KB, 210 KB, 468 KB and 491 KB in that order. If the best fit algorithm is used, which partitions are NOT allotted to an... | [
{
"code": null,
"e": 54,
"s": 26,
"text": "\n28 Jun, 2021"
},
{
"code": null,
"e": 372,
"s": 54,
"text": "Consider six memory partitions of size 200 KB, 400 KB, 600 KB, 500 KB, 300 KB, and 250 KB, where KB refers to kilobyte. These partitions need to be allotted to four processes... |
Box Plot | 22 Jan, 2021
Box Plot: It is a type of chart that depicts a group of numerical data through their quartiles. It is a simple way to visualize the shape of our data. It makes comparing characteristics of data between categories very easy.
In this article, we are going to discuss the following topics-
Understanding the co... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n22 Jan, 2021"
},
{
"code": null,
"e": 252,
"s": 28,
"text": "Box Plot: It is a type of chart that depicts a group of numerical data through their quartiles. It is a simple way to visualize the shape of our data. It makes comparing chara... |
Python | sympy.zeros() method | 29 Jun, 2019
With the help of sympy.zeros() method, we can create a matrix having dimension nxm and filled with zeros by using sympy.zeros() method.
Syntax : sympy.zeros()Return : Return a zero matrix.
Example #1 :In this example, we can see that by using sympy.zero() method, we are able to create the zero matrix havin... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n29 Jun, 2019"
},
{
"code": null,
"e": 164,
"s": 28,
"text": "With the help of sympy.zeros() method, we can create a matrix having dimension nxm and filled with zeros by using sympy.zeros() method."
},
{
"code": null,
"e": 21... |
GATE CS 2011 - GeeksforGeeks | 11 Oct, 2021
A layer-4 firewall (a device that can look at all protocol headers up to the transport layer) CANNOT
block entire HTTP traffic during 9:00PM and 5 :0OAM
block all ICMP traffic
stop incoming traffic from a specific IP address but allow outgoing traffic to the same IP address
block TCP traffic from a spe... | [
{
"code": null,
"e": 29577,
"s": 29549,
"text": "\n11 Oct, 2021"
},
{
"code": null,
"e": 29679,
"s": 29577,
"text": "A layer-4 firewall (a device that can look at all protocol headers up to the transport layer) CANNOT "
},
{
"code": null,
"e": 29732,
"s": 29679,
... |
Count of elements which form a loop in an Array according to given constraints | 15 Jun, 2021
Given an array A containing N integers, the task is to count the number of elements which form a cycle in the array, based on the following condition. Start to traverse the Array from index i and jump to its next connected index. A directed edge exits from index i of A to index j if j = GCD(i, A[i]) % N. I... | [
{
"code": null,
"e": 54,
"s": 26,
"text": "\n15 Jun, 2021"
},
{
"code": null,
"e": 492,
"s": 54,
"text": "Given an array A containing N integers, the task is to count the number of elements which form a cycle in the array, based on the following condition. Start to traverse the A... |
Tensors in Pytorch | 04 Jul, 2021
A Pytorch Tensor is basically the same as a NumPy array. This means it does not know anything about deep learning or computational graphs or gradients and is just a generic n-dimensional array to be used for arbitrary numeric computation. However, the biggest difference between a NumPy array and a PyTorch ... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n04 Jul, 2021"
},
{
"code": null,
"e": 474,
"s": 28,
"text": "A Pytorch Tensor is basically the same as a NumPy array. This means it does not know anything about deep learning or computational graphs or gradients and is just a generic n-... |
How to Count the Number of Repeated Characters in a Golang String? | 26 Aug, 2019
In Go language, strings are different from other languages like Java, C++, Python, etc. It is a sequence of variable-width characters where each and every character is represented by one or more bytes using UTF-8 Encoding.In Go string, you can count some specific Unicode code points or the number of non-ov... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n26 Aug, 2019"
},
{
"code": null,
"e": 690,
"s": 28,
"text": "In Go language, strings are different from other languages like Java, C++, Python, etc. It is a sequence of variable-width characters where each and every character is represe... |
Program to print a string in vertical zigzag manner | 06 Jul, 2021
Given a string, S of size N, and a number of rows R, the task is to print the given string in a vertical zigzag fashion with respect to the given number of rows as shown in the examples.
Examples:
Input: S = “123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz”, R = 9Output:
Input: S = “Attention... | [
{
"code": null,
"e": 52,
"s": 24,
"text": "\n06 Jul, 2021"
},
{
"code": null,
"e": 239,
"s": 52,
"text": "Given a string, S of size N, and a number of rows R, the task is to print the given string in a vertical zigzag fashion with respect to the given number of rows as shown in t... |
try-except vs If in Python | 13 Aug, 2021
Python is a widely used general-purpose, high level programming language. It was mainly developed for emphasis on code readability, and its syntax allows programmers to express concepts in fewer lines of code. Python is a programming language that lets you work quickly and integrate systems more efficientl... | [
{
"code": null,
"e": 52,
"s": 24,
"text": "\n13 Aug, 2021"
},
{
"code": null,
"e": 586,
"s": 52,
"text": "Python is a widely used general-purpose, high level programming language. It was mainly developed for emphasis on code readability, and its syntax allows programmers to expre... |
Find winner of an election where votes are represented as candidate names | 25 May, 2022
Given an array of names of candidates in an election. A candidate’s name in the array represents a vote cast on the candidate. Print the name of candidates who received the maximum vote. If there is a tie, print a lexicographically smaller name.
Examples:
Input : votes[] = {"john", "johnny", "jackie",
... | [
{
"code": null,
"e": 52,
"s": 24,
"text": "\n25 May, 2022"
},
{
"code": null,
"e": 298,
"s": 52,
"text": "Given an array of names of candidates in an election. A candidate’s name in the array represents a vote cast on the candidate. Print the name of candidates who received the m... |
Repeated subtraction among two numbers | 02 Mar, 2021
Given a pair of positive numbers x and y. We repeatedly subtract the smaller of the two integers from greater one until one of the integers becomes 0. The task is to count number of steps to before we stop (one of the numbers become 0). Examples :
Input : x = 5, y = 13
Output : 6
Explanation : There are t... | [
{
"code": null,
"e": 52,
"s": 24,
"text": "\n02 Mar, 2021"
},
{
"code": null,
"e": 301,
"s": 52,
"text": "Given a pair of positive numbers x and y. We repeatedly subtract the smaller of the two integers from greater one until one of the integers becomes 0. The task is to count nu... |
gcd() in Python | 30 May, 2022
The Highest Common Factor (HCF), also called gcd, can be computed in python using a single function offered by math module and hence can make tasks easier in many situations.
Python3
# Python code to demonstrate naive# method to compute gcd ( recursion ) def hcfnaive(a, b): if(b == 0): return abs... | [
{
"code": null,
"e": 52,
"s": 24,
"text": "\n30 May, 2022"
},
{
"code": null,
"e": 227,
"s": 52,
"text": "The Highest Common Factor (HCF), also called gcd, can be computed in python using a single function offered by math module and hence can make tasks easier in many situations.... |
How to set the offset property for ScrollSpy in Bootstrap ? - GeeksforGeeks | 08 Jul, 2020
Offset is a Bootstrap Scrollspy property wherein the user can specify the pixels to offset from top when calculating the position of scroll. It becomes useful when the user feels that either the navbar or the list changes the state early or when not needed while surfing. It is always a number and the defau... | [
{
"code": null,
"e": 26029,
"s": 26001,
"text": "\n08 Jul, 2020"
},
{
"code": null,
"e": 26446,
"s": 26029,
"text": "Offset is a Bootstrap Scrollspy property wherein the user can specify the pixels to offset from top when calculating the position of scroll. It becomes useful when... |
Proving elements of a finite group is finite - GeeksforGeeks | 17 Mar, 2021
To Prove : The order of every element of a finite group is finite and is less than or equal to the order of the group.
Proof : Suppose G is a finite group, the composition being denoted multiplicatively. Suppose a ∈ G, consider all positive integral powers of a i.e., a, a2, a3, ...... All these are eleme... | [
{
"code": null,
"e": 26137,
"s": 26109,
"text": "\n17 Mar, 2021"
},
{
"code": null,
"e": 26257,
"s": 26137,
"text": "To Prove : The order of every element of a finite group is finite and is less than or equal to the order of the group. "
},
{
"code": null,
"e": 26588,... |
Python | time.mktime() method - GeeksforGeeks | 17 Sep, 2019
time.mktime() method of Time module is used to convert a time.struct_time object or a tuple containing 9 elements corresponding to time.struct_time object to time in seconds passed since epoch in local time.
This method is the inverse function of time.localtime() which converts the time expressed in second... | [
{
"code": null,
"e": 25537,
"s": 25509,
"text": "\n17 Sep, 2019"
},
{
"code": null,
"e": 25745,
"s": 25537,
"text": "time.mktime() method of Time module is used to convert a time.struct_time object or a tuple containing 9 elements corresponding to time.struct_time object to time ... |
Dynamic ImageButton in Kotlin - GeeksforGeeks | 28 Mar, 2022
Android ImageButton is a user interface widget which is used to display a button having image and to perform exactly like button when we click on it but here, we add an image on Image button instead of text. There are different types of buttons available in android like ImageButton, ToggleButton etc.
We ca... | [
{
"code": null,
"e": 25257,
"s": 25229,
"text": "\n28 Mar, 2022"
},
{
"code": null,
"e": 25559,
"s": 25257,
"text": "Android ImageButton is a user interface widget which is used to display a button having image and to perform exactly like button when we click on it but here, we a... |
JavaScript Course | Data Types in JavaScript - GeeksforGeeks | 29 Apr, 2019
Previous article: JavaScript Course | Variables in JavaScript
Datatypes in JavaScript
There are majorly two types of languages. First, one is Statically typed language where each variable and expression type is already known at compile time. Once a variable is declared to be of a certain data type, it cann... | [
{
"code": null,
"e": 25925,
"s": 25897,
"text": "\n29 Apr, 2019"
},
{
"code": null,
"e": 25987,
"s": 25925,
"text": "Previous article: JavaScript Course | Variables in JavaScript"
},
{
"code": null,
"e": 26011,
"s": 25987,
"text": "Datatypes in JavaScript"
}... |
Data Structures | Heap | Question 9 - GeeksforGeeks | 28 Jun, 2021
In a binary max heap containing n numbers, the smallest element can be found in time (GATE CS 2006)(A) 0(n)(B) O(logn)(C) 0(loglogn)(D) 0(1)Answer: (A)Explanation: In a max heap, the smallest element is always present at a leaf node. So we need to check for all leaf nodes for the minimum value. Worst case ... | [
{
"code": null,
"e": 26061,
"s": 26033,
"text": "\n28 Jun, 2021"
},
{
"code": null,
"e": 26392,
"s": 26061,
"text": "In a binary max heap containing n numbers, the smallest element can be found in time (GATE CS 2006)(A) 0(n)(B) O(logn)(C) 0(loglogn)(D) 0(1)Answer: (A)Explanation:... |
Print the DFS traversal step-wise (Backtracking also) - GeeksforGeeks | 14 Sep, 2021
Given a graph, the task is to print the DFS traversal of a graph which includes every step including the backtracking.
1st step:- 0 -> 1
2nd step:- 1 -> 5
3rd step:- 5 -> 1 (backtracking step)
4th step:- 1 -> 6...
and so on till all the nodes are visited.
Dfs step-wise(including backtracking) is:
0 1 5 1... | [
{
"code": null,
"e": 25733,
"s": 25705,
"text": "\n14 Sep, 2021"
},
{
"code": null,
"e": 25852,
"s": 25733,
"text": "Given a graph, the task is to print the DFS traversal of a graph which includes every step including the backtracking."
},
{
"code": null,
"e": 26068,
... |
PostgreSQL - Recursive Query Using CTEs - GeeksforGeeks | 11 Aug, 2021
Strictly speaking, this process is iteration, not recursion, but RECURSIVE is the terminology chosen by the SQL standards committee.
The general structure of the Postgres recursive query contains,
Non-recursive select statementUnion or union allRecursive select statement
Non-recursive select statement
Uni... | [
{
"code": null,
"e": 25367,
"s": 25339,
"text": "\n11 Aug, 2021"
},
{
"code": null,
"e": 25500,
"s": 25367,
"text": "Strictly speaking, this process is iteration, not recursion, but RECURSIVE is the terminology chosen by the SQL standards committee."
},
{
"code": null,
... |
Higher-Order Function in Golang - GeeksforGeeks | 16 Jun, 2021
In Go, language, a function is called a Higher-Order Function if it fulfills one of the following conditions:1. Passing Functions as an Argument to Another Function:If a function is passed as an argument to another function, then such types of functions are known as a Higher-Order function. This passing fu... | [
{
"code": null,
"e": 25499,
"s": 25471,
"text": "\n16 Jun, 2021"
},
{
"code": null,
"e": 26238,
"s": 25499,
"text": "In Go, language, a function is called a Higher-Order Function if it fulfills one of the following conditions:1. Passing Functions as an Argument to Another Functio... |
Hamming Code in Computer Network - GeeksforGeeks | 04 May, 2020
Hamming code is a set of error-correction codes that can be used to detect and correct the errors that can occur when the data is moved or stored from the sender to the receiver. It is technique developed by R.W. Hamming for error correction.
Redundant bits –
Redundant bits are extra binary bits that are g... | [
{
"code": null,
"e": 37839,
"s": 37811,
"text": "\n04 May, 2020"
},
{
"code": null,
"e": 38082,
"s": 37839,
"text": "Hamming code is a set of error-correction codes that can be used to detect and correct the errors that can occur when the data is moved or stored from the sender t... |
Google Chrome Dino Bot using Image Recognition | Python - GeeksforGeeks | 30 Nov, 2021
What would you see in your Chrome browser when there is no internet connection ? Yes, everybody knows that dinosaur game that comes on screen. So, in this article, we are going to build a simple python bot that plays Chrome Dino Game without user interaction. Here we are not using any machine learning or a... | [
{
"code": null,
"e": 25723,
"s": 25695,
"text": "\n30 Nov, 2021"
},
{
"code": null,
"e": 26127,
"s": 25723,
"text": "What would you see in your Chrome browser when there is no internet connection ? Yes, everybody knows that dinosaur game that comes on screen. So, in this article,... |
Process Management in Linux - GeeksforGeeks | 17 May, 2020
A process means program in execution. It generally takes an input, processes it and gives us the appropriate output. Check Introduction to Process Management for more details about a process. There are basically 2 types of processes.
Foreground processes: Such kind of processes are also known as interactiv... | [
{
"code": null,
"e": 25651,
"s": 25623,
"text": "\n17 May, 2020"
},
{
"code": null,
"e": 25885,
"s": 25651,
"text": "A process means program in execution. It generally takes an input, processes it and gives us the appropriate output. Check Introduction to Process Management for m... |
Perl | Modules - GeeksforGeeks | 17 Feb, 2019
A module in Perl is a collection of related subroutines and variables that perform a set of programming tasks. Perl Modules are reusable. Various Perl modules are available on the Comprehensive Perl Archive Network (CPAN). These modules cover a wide range of categories such as network, CGI, XML processing,... | [
{
"code": null,
"e": 26525,
"s": 26497,
"text": "\n17 Feb, 2019"
},
{
"code": null,
"e": 26861,
"s": 26525,
"text": "A module in Perl is a collection of related subroutines and variables that perform a set of programming tasks. Perl Modules are reusable. Various Perl modules are ... |
Implementation of Logistic Regression from Scratch using Python - GeeksforGeeks | 25 Oct, 2020
Logistic Regression is a supervised learning algorithm that is used when the target variable is categorical. Hypothetical function h(x) of linear regression predicts unbounded values. But in the case of Logistic Regression, where the target variable is categorical we have to strict the range of predicted v... | [
{
"code": null,
"e": 25589,
"s": 25561,
"text": "\n25 Oct, 2020"
},
{
"code": null,
"e": 26153,
"s": 25589,
"text": "Logistic Regression is a supervised learning algorithm that is used when the target variable is categorical. Hypothetical function h(x) of linear regression predic... |
Dart - Comments - GeeksforGeeks | 12 Nov, 2021
In every programming language comments play an important role for a better understanding of the code in the future or by any other programmer. Comments are a set of statements that are not meant to be executed by the compiler. They provide proper documentation of the code.
Types of Dart Comments:
Dart Si... | [
{
"code": null,
"e": 25285,
"s": 25257,
"text": "\n12 Nov, 2021"
},
{
"code": null,
"e": 25560,
"s": 25285,
"text": "In every programming language comments play an important role for a better understanding of the code in the future or by any other programmer. Comments are a set o... |
Create a shortcut key to activate an element in HTML | To create a shortcut key, use the access attribute in HTML. Let us say you need to add a shortcut key to the following link
Hadoop Tutorial
To let shortcut keys work correctly on Firefox web browser (Windows), you need to add it like this −
[Alt] [Shift] + accesskey
You can try to run the following code to create a sho... | [
{
"code": null,
"e": 1186,
"s": 1062,
"text": "To create a shortcut key, use the access attribute in HTML. Let us say you need to add a shortcut key to the following link"
},
{
"code": null,
"e": 1202,
"s": 1186,
"text": "Hadoop Tutorial"
},
{
"code": null,
"e": 1303,... |
Redis - Sorted Set Zinterstore Command | Redis ZINTERSTORE command computes the intersection of numkeys sorted sets given by the specified keys, and stores the result in the destination. It is mandatory to provide the number of input keys (numkeys) before passing the input keys and the other (optional) arguments.
Integer reply, the number of elements in the r... | [
{
"code": null,
"e": 2319,
"s": 2045,
"text": "Redis ZINTERSTORE command computes the intersection of numkeys sorted sets given by the specified keys, and stores the result in the destination. It is mandatory to provide the number of input keys (numkeys) before passing the input keys and the other (... |
DateTime.GetDateTimeFormats() Method in C# | The DateTime.GetDateTimeFormats() method in C# is used to convert the value of this instance to all the string representations supported by the standard date and time format specifiers.
Following is the syntax −
public string[] GetDateTimeFormats ()
public string[] GetDateTimeFormats (char ch);
Above, ch is a standard ... | [
{
"code": null,
"e": 1248,
"s": 1062,
"text": "The DateTime.GetDateTimeFormats() method in C# is used to convert the value of this instance to all the string representations supported by the standard date and time format specifiers."
},
{
"code": null,
"e": 1274,
"s": 1248,
"text... |
How to get first day of week in PHP? - GeeksforGeeks | 07 Feb, 2019
Use strtotime() function to get the first day of week using PHP. This function returns the default time variable timestamp and then use date() function to convert timestamp date into understandable date.
strtotime() Function: The strtotime() function returns the result in timestamp by parsing the time stri... | [
{
"code": null,
"e": 24640,
"s": 24612,
"text": "\n07 Feb, 2019"
},
{
"code": null,
"e": 24844,
"s": 24640,
"text": "Use strtotime() function to get the first day of week using PHP. This function returns the default time variable timestamp and then use date() function to convert ... |
Find the sum of N terms of the series 1, 4, 13, 40, 121, ... - GeeksforGeeks | 21 Jan, 2022
Given a positive integer, n. Find the sum of the first n term of the series:
1, 4, 13, 40, 121, .....
Examples:
Input: n = 5Output: 179
Input: n = 3Output: 18
Approach:
The sequence is formed by using the following pattern. For any value N-
The above solution can be derived following the series of steps-
L... | [
{
"code": null,
"e": 26350,
"s": 26322,
"text": "\n21 Jan, 2022"
},
{
"code": null,
"e": 26427,
"s": 26350,
"text": "Given a positive integer, n. Find the sum of the first n term of the series:"
},
{
"code": null,
"e": 26452,
"s": 26427,
"text": "1, 4, 13, 40,... |
Convert a string to hexadecimal ASCII values | 26 May, 2022
Given a string as input, write a program to convert the characters of the given string into the hexadecimal equivalent of ASCII values. Examples :
Input : Geek
Output : 4765656b
Input : IronMan part 3
Output : 49726f6e4d616e20706172742033
ASCII stands for American Standard Code for Information Intercha... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n26 May, 2022"
},
{
"code": null,
"e": 176,
"s": 28,
"text": "Given a string as input, write a program to convert the characters of the given string into the hexadecimal equivalent of ASCII values. Examples : "
},
{
"code": null,... |
Program to determine the Quadrant of a Complex number | 19 May, 2021
Given a complex number in the form of the string str, the task is to determine the quadrant of the cartesian plane in which this complex number lies.
Examples:
Input: str = “1 + 1i” Output: Quadrant 1
Input: str = “0 + 0i” Output: Origin
Approach:
The idea is to first find the real and imaginary parts of ... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n19 May, 2021"
},
{
"code": null,
"e": 178,
"s": 28,
"text": "Given a complex number in the form of the string str, the task is to determine the quadrant of the cartesian plane in which this complex number lies."
},
{
"code": nul... |
Spring Boot – Integrating Hibernate and JPA | 03 Jan, 2022
Spring Boot is built on the top of the spring and contains all the features of spring. And is becoming a favorite of developers these days because of its rapid production-ready environment which enables the developers to directly focus on the logic instead of struggling with the configuration and setup. Sp... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n03 Jan, 2022"
},
{
"code": null,
"e": 451,
"s": 28,
"text": "Spring Boot is built on the top of the spring and contains all the features of spring. And is becoming a favorite of developers these days because of its rapid production-read... |
Semantic Analysis in Compiler Design | 22 Apr, 2020
Semantic Analysis is the third phase of Compiler. Semantic Analysis makes sure that declarations and statements of program are semantically correct. It is a collection of procedures which is called by parser as and when required by grammar. Both syntax tree of previous phase and symbol table are used to ch... | [
{
"code": null,
"e": 52,
"s": 24,
"text": "\n22 Apr, 2020"
},
{
"code": null,
"e": 522,
"s": 52,
"text": "Semantic Analysis is the third phase of Compiler. Semantic Analysis makes sure that declarations and statements of program are semantically correct. It is a collection of pro... |
JavaScript | Let | 06 Jun, 2022
let is a keyword used to declare variables in JavaScript that are block scoped. There are three ways you can declare variables in JavaScript let, const, var(old). Like other keywords, let keyword could be easily used inside or outside a function as per user requirement. ES6 or ES2015 defines new keywords t... | [
{
"code": null,
"e": 53,
"s": 25,
"text": "\n06 Jun, 2022"
},
{
"code": null,
"e": 629,
"s": 53,
"text": "let is a keyword used to declare variables in JavaScript that are block scoped. There are three ways you can declare variables in JavaScript let, const, var(old). Like other ... |
JavaScript | Pad a number with leading zeros | 20 May, 2019
The String prototype property is used to pad a number with leading zeros. This property allows for adding new properties and methods to existing object types.
Syntax:
object.prototype.name = value
Return value: It returns a reference to the String.prototype object.
Example 1: This example adds leading zero... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n20 May, 2019"
},
{
"code": null,
"e": 187,
"s": 28,
"text": "The String prototype property is used to pad a number with leading zeros. This property allows for adding new properties and methods to existing object types."
},
{
"c... |
Difference Between Imperative and Declarative Programming | 07 Jul, 2021
A programming paradigm is an approach to solve problems using some programming language or also we can say it is a method to solve a problem using tools and techniques that are available to us following some approach. There are lots of programming languages that are known but all of them need to follow som... | [
{
"code": null,
"e": 54,
"s": 26,
"text": "\n07 Jul, 2021"
},
{
"code": null,
"e": 551,
"s": 54,
"text": "A programming paradigm is an approach to solve problems using some programming language or also we can say it is a method to solve a problem using tools and techniques that a... |
C | Advanced Pointer | Question 1 - GeeksforGeeks | 28 Jun, 2021
void fun(int *p) { int q = 10; p = &q; } int main() { int r = 20; int *p = &r; fun(p); printf("%d", *p); return 0; }
(A) 10(B) 20(C) Compiler error(D) Runtime ErrorAnswer: (B)Explanation: Inside fun(), q is a copy of the pointer p. So if we change q to point something else then p rema... | [
{
"code": null,
"e": 24073,
"s": 24045,
"text": "\n28 Jun, 2021"
},
{
"code": "void fun(int *p) { int q = 10; p = &q; } int main() { int r = 20; int *p = &r; fun(p); printf(\"%d\", *p); return 0; }",
"e": 24212,
"s": 24073,
"text": null
},
{
"code": ... |
Calculate the curl of a vector field in Python and plot it with Matplotlib | To calculate the curl of a vector field in Python and plot in with Matplotlib, we can use quiver() method and calculate the corresponding data.
Set the figure size and adjust the padding between and around the subplots.
Create a new figure or activate an existing figure using figure() method.
Add a 3D axes to the figur... | [
{
"code": null,
"e": 1206,
"s": 1062,
"text": "To calculate the curl of a vector field in Python and plot in with Matplotlib, we can use quiver() method and calculate the corresponding data."
},
{
"code": null,
"e": 1282,
"s": 1206,
"text": "Set the figure size and adjust the pad... |
Tryit Editor v3.7 | Tryit: HTML border collapse | [] |
5 Code Knowledge Points About Python TimeDelta | Towards Data Science | As one of the most important built-in libraries in Python, the “datetime” library is a must-learn for any Python learners. In this library, “timedelta” which indicates a time interval, is the module that I like the most. It provides many useful functions that let us achieve features out-of-the-box, as well as enable th... | [
{
"code": null,
"e": 644,
"s": 172,
"text": "As one of the most important built-in libraries in Python, the “datetime” library is a must-learn for any Python learners. In this library, “timedelta” which indicates a time interval, is the module that I like the most. It provides many useful functions ... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.