title
stringlengths
3
221
text
stringlengths
17
477k
parsed
listlengths
0
3.17k
Find sum of all left leaves in a given Binary Tree
24 Jun, 2022 Given a Binary Tree, find the sum of all left leaves in it. For example, sum of all left leaves in below Binary Tree is 5+1=6. The idea is to traverse the tree, starting from root. For every node, check if its left subtree is a leaf. If it is, then add it to the result. Following is the implementation of t...
[ { "code": null, "e": 52, "s": 24, "text": "\n24 Jun, 2022" }, { "code": null, "e": 179, "s": 52, "text": "Given a Binary Tree, find the sum of all left leaves in it. For example, sum of all left leaves in below Binary Tree is 5+1=6." }, { "code": null, "e": 374, "...
Generative Adversarial Network (GAN)
15 Jan, 2019 Generative Adversarial Networks (GANs) are a powerful class of neural networks that are used for unsupervised learning. It was developed and introduced by Ian J. Goodfellow in 2014. GANs are basically made up of a system of two competing neural network models which compete with each other and are able to a...
[ { "code": null, "e": 54, "s": 26, "text": "\n15 Jan, 2019" }, { "code": null, "e": 419, "s": 54, "text": "Generative Adversarial Networks (GANs) are a powerful class of neural networks that are used for unsupervised learning. It was developed and introduced by Ian J. Goodfellow i...
Print a Spirograph using turtle in Python
11 Sep, 2021 Pre-requisites: Turtle Programming in Python A spirograph is a very interesting geometrical figure which is often symmetrical to both the axes. It produces mathematical roulette curves of the variety technically known as hypotrochoids and epitrochoids. Here, we’ve used a range of colors to draw circles, yo...
[ { "code": null, "e": 53, "s": 25, "text": "\n11 Sep, 2021" }, { "code": null, "e": 98, "s": 53, "text": "Pre-requisites: Turtle Programming in Python" }, { "code": null, "e": 413, "s": 98, "text": "A spirograph is a very interesting geometrical figure which is...
Program to Convert Km/hr to miles/hr and vice versa
31 May, 2022 Given a speed in km/hr, Convert it to m/hr and m/hr to km/hr. Examples: Input : 150 (km/hr) Output : 93.21 Input : 100 (m/hr) Output : 160.92693917 The conversion formula for kph to mph is – 1 kilo-meter = 0.621371192 miles The conversion formula for mph to kph is – 1 miles = 1.60934 kilo-meter C++ ...
[ { "code": null, "e": 28, "s": 0, "text": "\n31 May, 2022" }, { "code": null, "e": 91, "s": 28, "text": "Given a speed in km/hr, Convert it to m/hr and m/hr to km/hr. " }, { "code": null, "e": 102, "s": 91, "text": "Examples: " }, { "code": null, "e...
norm() function in C++ with Examples
10 Oct, 2018 The norm() function is defined in the complex header file. This function is used to return the squared magnitude of the complex number z. Syntax: template<class T> T norm (const complex<T>& z); Parameter: z: It represents the given complex number. Return: It returns the squared magnitude of the complex nu...
[ { "code": null, "e": 28, "s": 0, "text": "\n10 Oct, 2018" }, { "code": null, "e": 166, "s": 28, "text": "The norm() function is defined in the complex header file. This function is used to return the squared magnitude of the complex number z." }, { "code": null, "e": ...
HTML DOM createRange() Method
29 Jul, 2020 The createRange() method creates a new Range object for the document. Syntax: range = document.createRange(); Parameters: This method does not accept any parameters. Return Value: This method returns the created Range. Example: In this example, we will create a range using this method, a range should not b...
[ { "code": null, "e": 28, "s": 0, "text": "\n29 Jul, 2020" }, { "code": null, "e": 98, "s": 28, "text": "The createRange() method creates a new Range object for the document." }, { "code": null, "e": 106, "s": 98, "text": "Syntax:" }, { "code": null, ...
How to trigger the same function with jQuery multiple events?
To trigger the same function with multiple events, use the jQuery on() method with multiple events such as click, dblclick, mouse enter, mouse leave, hover, etc. You can try to run the following code to learn how to work the same function with jQuery multiple events: Live Demo <!DOCTYPE html> <html> <head> <script src=...
[ { "code": null, "e": 1224, "s": 1062, "text": "To trigger the same function with multiple events, use the jQuery on() method with multiple events such as click, dblclick, mouse enter, mouse leave, hover, etc." }, { "code": null, "e": 1330, "s": 1224, "text": "You can try to run t...
How to create a blink text using JavaScript?
To create a blinking text, use the JavaScript blink() method. This method causes a string to blink as if it were in a BLINK tag. Note − HTML <blink> tag deprecated and is not expected to work in every browser. You can try to run the following code to create a blinking text with the JavaScript blink() method − Live Demo...
[ { "code": null, "e": 1191, "s": 1062, "text": "To create a blinking text, use the JavaScript blink() method. This method causes a string to blink as if it were in a BLINK tag." }, { "code": null, "e": 1272, "s": 1191, "text": "Note − HTML <blink> tag deprecated and is not expecte...
scipy.stats.chi2() | Python - GeeksforGeeks
20 Mar, 2019 scipy.stats.chi2() is an chi square continuous random variable that is defined with a standard format and some shape parameters to complete its specification. Parameters :q : lower and upper tail probabilityx : quantilesloc : [optional]location parameter. Default = 0scale : [optional]scale parameter. Defau...
[ { "code": null, "e": 24806, "s": 24778, "text": "\n20 Mar, 2019" }, { "code": null, "e": 24965, "s": 24806, "text": "scipy.stats.chi2() is an chi square continuous random variable that is defined with a standard format and some shape parameters to complete its specification." }...
TypeScript - Array indexOf()
indexOf() method returns the first index at which a given element can be found in the array, or -1 if it is not present. array.indexOf(searchElement[, fromIndex]); searchElement − Element to locate in the array. searchElement − Element to locate in the array. fromIndex − The index at which to begin the search. Default...
[ { "code": null, "e": 2169, "s": 2048, "text": "indexOf() method returns the first index at which a given element can be found in the array, or -1 if it is not present." }, { "code": null, "e": 2213, "s": 2169, "text": "array.indexOf(searchElement[, fromIndex]);\n" }, { "c...
Convert an Array to an Object in JavaScript - GeeksforGeeks
14 May, 2019 Here is a need to convert an array into an object. To do so we are going to use a few of the most preferred methods. First here is a method to know.Object.assign() methodThis method copies the values of all enumerable own properties from source objects(one or more) to a target object.Syntax: Object.assign(...
[ { "code": null, "e": 24909, "s": 24881, "text": "\n14 May, 2019" }, { "code": null, "e": 25202, "s": 24909, "text": "Here is a need to convert an array into an object. To do so we are going to use a few of the most preferred methods. First here is a method to know.Object.assign()...
How to create your own Question-Answering system easily with python | by André Macedo Farias | Towards Data Science
The history of Machine Comprehension (MC) has its origins along with the birth of first concepts in Artificial Intelligence (AI). The brilliant Allan Turing proposed in his famous article “Computing Machinery and Intelligence” what is now called the Turing test as a criterion of intelligence. Almost 70 years later, Que...
[ { "code": null, "e": 581, "s": 171, "text": "The history of Machine Comprehension (MC) has its origins along with the birth of first concepts in Artificial Intelligence (AI). The brilliant Allan Turing proposed in his famous article “Computing Machinery and Intelligence” what is now called the Turin...
C# | Array Class - GeeksforGeeks
05 Aug, 2021 The Array class gives methods for creating, manipulating, searching, and sorting arrays. The Array class is not part of the System.Collections namespace, but it is still considered as a collection because it is based on the IList interface. The Array class is the base class for language implementations tha...
[ { "code": null, "e": 24889, "s": 24861, "text": "\n05 Aug, 2021" }, { "code": null, "e": 25214, "s": 24889, "text": "The Array class gives methods for creating, manipulating, searching, and sorting arrays. The Array class is not part of the System.Collections namespace, but it is...
How to access Pandas Series elements by using indexing?
The data present in the pandas Series object has indexing labels, those index labels are used to access or retrieve elements. Each index value addresses an element in series. Indexes are basically represented in two types: positional indexing and labeled indexing. Positional indexing is nothing but integer values start...
[ { "code": null, "e": 1237, "s": 1062, "text": "The data present in the pandas Series object has indexing labels, those index labels are used to access or retrieve elements. Each index value addresses an element in series." }, { "code": null, "e": 1556, "s": 1237, "text": "Indexes...
Understanding and Coding a ResNet in Keras | by Priya Dwivedi | Towards Data Science
ResNet, short for Residual Networks is a classic neural network used as a backbone for many computer vision tasks. This model was the winner of ImageNet challenge in 2015. The fundamental breakthrough with ResNet was it allowed us to train extremely deep neural networks with 150+layers successfully. Prior to ResNet tra...
[ { "code": null, "e": 580, "s": 171, "text": "ResNet, short for Residual Networks is a classic neural network used as a backbone for many computer vision tasks. This model was the winner of ImageNet challenge in 2015. The fundamental breakthrough with ResNet was it allowed us to train extremely deep ...
Comparator thenComparingInt() method in Java with examples - GeeksforGeeks
29 Apr, 2019 The thenComparingInt(java.util.function.ToIntFunction) method of Comparator Interface in Java returns a lexicographic-order comparator with a function that extracts a int sort key. Syntax: default Comparator <T> thenComparingInt(ToIntFunction <T> keyExtractor) Parameters: This method accepts keyExtra...
[ { "code": null, "e": 23557, "s": 23529, "text": "\n29 Apr, 2019" }, { "code": null, "e": 23738, "s": 23557, "text": "The thenComparingInt(java.util.function.ToIntFunction) method of Comparator Interface in Java returns a lexicographic-order comparator with a function that extract...
Can a method have the same name as the class?
Yes, you can write a method in Java with method name same as class name. But it is not suggestable because of the following reasons − Using upper case letter at the starting of the name of the method violates the coding conventions of Java for writing a methods name. There is a chance of assuming such methods with cons...
[ { "code": null, "e": 1196, "s": 1062, "text": "Yes, you can write a method in Java with method name same as class name. But it is not suggestable because of the following reasons −" }, { "code": null, "e": 1330, "s": 1196, "text": "Using upper case letter at the starting of the n...
Ansible - Environment Setup
In this chapter, we will learn about the environment setup of Ansible. Mainly, there are two types of machines when we talk about deployment − Control machine − Machine from where we can manage other machines. Control machine − Machine from where we can manage other machines. Remote machine − Machines which are handled...
[ { "code": null, "e": 1862, "s": 1791, "text": "In this chapter, we will learn about the environment setup of Ansible." }, { "code": null, "e": 1934, "s": 1862, "text": "Mainly, there are two types of machines when we talk about deployment −" }, { "code": null, "e": 20...
Generate Modern Stylish Wordcloud with stylecloud | by AbdulMajedRaja RS | Towards Data Science
Almost every Text Analytics Project with a need to find insights from Text Corpus would contain a word cloud. But as many of you remember, Wordclouds have got a very boring image and perception in the minds of a data scientist that we always try to beautify them — ultimately giving up in the process — except a few woul...
[ { "code": null, "e": 637, "s": 171, "text": "Almost every Text Analytics Project with a need to find insights from Text Corpus would contain a word cloud. But as many of you remember, Wordclouds have got a very boring image and perception in the minds of a data scientist that we always try to beauti...
Count of numbers in the range [L, R] which satisfy the given conditions - GeeksforGeeks
19 Jan, 2022 Given a range [L, R], the task is to find the count of numbers from this range that satisfy the below conditions: All the digit in the number are distinct.All the digits are less than or equal to 5. All the digit in the number are distinct. All the digits are less than or equal to 5. Examples: Input: L...
[ { "code": null, "e": 25791, "s": 25763, "text": "\n19 Jan, 2022" }, { "code": null, "e": 25907, "s": 25791, "text": "Given a range [L, R], the task is to find the count of numbers from this range that satisfy the below conditions: " }, { "code": null, "e": 25992, ...
Tryit Editor v3.7
Tryit: Video autoplay
[]
How to Add Fingerprint Authentication in Your Android App without Using any Library? - GeeksforGeeks
27 May, 2021 Biometric Fingerprint authentication is one method of protecting sensitive information or premium content of your app. Nowadays, all payment apps use this feature in their app. It is very easy to implement. A sample Video is given below to get an idea about what we are going to do in this article. Note tha...
[ { "code": null, "e": 25260, "s": 25232, "text": "\n27 May, 2021" }, { "code": null, "e": 25645, "s": 25260, "text": "Biometric Fingerprint authentication is one method of protecting sensitive information or premium content of your app. Nowadays, all payment apps use this feature ...
How to test and execute a regular expression in JavaScript?
Following is the code for testing and executing a regular expression in JavaScript − Live Demo <!DOCTYPE html> <html lang="en" > <head> <meta charset="UTF-8" /> <meta name="viewport" content="width=device-width, initial-scale=1.0" /> <title>Document</title> <style> body { font-family: "Segoe UI", Tahoma, Gene...
[ { "code": null, "e": 1147, "s": 1062, "text": "Following is the code for testing and executing a regular expression in JavaScript −" }, { "code": null, "e": 1158, "s": 1147, "text": " Live Demo" }, { "code": null, "e": 2249, "s": 1158, "text": "<!DOCTYPE html>...
Crop Image with OpenCV-Python - GeeksforGeeks
10 Oct, 2021 Cropping an Image is one of the most basic image operations that we perform in our projects. In this article, w will discuss how to crop images using OpenCV in Python. For this, we will take the image shown below. cv2.imread() method loads an image from the specified file. If the image cannot be read (bec...
[ { "code": null, "e": 24212, "s": 24184, "text": "\n10 Oct, 2021" }, { "code": null, "e": 24380, "s": 24212, "text": "Cropping an Image is one of the most basic image operations that we perform in our projects. In this article, w will discuss how to crop images using OpenCV in Pyt...
Complex Numbers in Python?
A complex number is created from real numbers. Python complex number can be created either using direct assignment statement or by using complex () function. Complex numbers which are mostly used where we are using two real numbers. For instance, an electric circuit which is defined by voltage(V) and current(C) are use...
[ { "code": null, "e": 1220, "s": 1062, "text": "A complex number is created from real numbers. Python complex number can be created either using direct assignment statement or by using complex () function." }, { "code": null, "e": 1435, "s": 1220, "text": "Complex numbers which ar...
C# | Math.Tanh() Method - GeeksforGeeks
13 Dec, 2021 Math.Tanh() is the inbuilt Math class method which returns the hyperbolic tan of a given double value argument. The result will be NaN if the given argument is NaN.Syntax: public static double Tanh(double num) Parameter: num: It is the number whose hyperbolic tan is to be returned and type of this paramet...
[ { "code": null, "e": 25745, "s": 25717, "text": "\n13 Dec, 2021" }, { "code": null, "e": 25917, "s": 25745, "text": "Math.Tanh() is the inbuilt Math class method which returns the hyperbolic tan of a given double value argument. The result will be NaN if the given argument is NaN...
C# | Remove elements from a HashSet with conditions defined by the predicate - GeeksforGeeks
01 Feb, 2019 A HashSet is an unordered collection of the unique elements. It comes under System.Collections.Generic namespace. It is used in a situation where we want to prevent duplicates from being inserted in the collection. As far as performance is concerned, it is better in comparison to the list. HashSet<T>.Remov...
[ { "code": null, "e": 24736, "s": 24708, "text": "\n01 Feb, 2019" }, { "code": null, "e": 25027, "s": 24736, "text": "A HashSet is an unordered collection of the unique elements. It comes under System.Collections.Generic namespace. It is used in a situation where we want to preven...
Find the only repeating element in a sorted array of size n - GeeksforGeeks
24 Jan, 2022 Given a sorted array of n elements containing elements in range from 1 to n-1 i.e. one element occurs twice, the task is to find the repeating element in an array.Examples : Input : arr[] = { 1, 2 , 3 , 4 , 4} Output : 4 Input : arr[] = { 1 , 1 , 2 , 3 , 4} Output : 1 A naive approach is to scan t...
[ { "code": null, "e": 26781, "s": 26753, "text": "\n24 Jan, 2022" }, { "code": null, "e": 26957, "s": 26781, "text": "Given a sorted array of n elements containing elements in range from 1 to n-1 i.e. one element occurs twice, the task is to find the repeating element in an array....
How to check the version of CodeIgniter framework ? - GeeksforGeeks
22 Oct, 2021 CodeIgniter is a powerful PHP framework used to create and design projects. The functionality and method calls are dependent on the CodeIgniter framework. The methods get deprecated based on the version of PHP and some of the functionality is specific to the browser. Therefore, it is important to check the...
[ { "code": null, "e": 24581, "s": 24553, "text": "\n22 Oct, 2021" }, { "code": null, "e": 24976, "s": 24581, "text": "CodeIgniter is a powerful PHP framework used to create and design projects. The functionality and method calls are dependent on the CodeIgniter framework. The meth...
Flatten binary tree to linked list | Practice | GeeksforGeeks
Given a binary tree, flatten it into linked list in-place. Usage of auxiliary data structure is not allowed. After flattening, left of each node should point to NULL and right should contain next node in preorder. Example 1: Input : 1 / \ 2 5 / \ \ 3 4 6 Output : 1 2...
[ { "code": null, "e": 452, "s": 238, "text": "Given a binary tree, flatten it into linked list in-place. Usage of auxiliary data structure is not allowed. After flattening, left of each node should point to NULL and right should contain next node in preorder." }, { "code": null, "e": 463,...
DateTime.ToUniversalTime() Method in C#
The DateTime.ToUniversalTime() method in C# is used to convert the value of the current DateTime object to Coordinated Universal Time (UTC). Following is the syntax − public DateTime ToUniversalTime (); Let us now see an example to implement the DateTime.ToUniversalTime() method − using System; public class Demo { p...
[ { "code": null, "e": 1203, "s": 1062, "text": "The DateTime.ToUniversalTime() method in C# is used to convert the value of the current DateTime object to Coordinated Universal Time (UTC)." }, { "code": null, "e": 1229, "s": 1203, "text": "Following is the syntax −" }, { "...
Find Occurrence of Number More Than N/2 Times in a Sorted Array in Java - GeeksforGeeks
27 Jun, 2021 Given a Sorted Array of n integers, and an Integer X, the task is to find whether the given Integer X appears more than n/2 times in the array or not. Input: arr[] = {1,1,2,3,3,3,3,3,3,3,3,3,4,5,6,6,7}, x=3 Output: 3 occurs 9 times which is more than 8 times Input: arr[] = {1,1,2,3,3,3,3,3,3,3,3,3,4,5,6,6...
[ { "code": null, "e": 23948, "s": 23920, "text": "\n27 Jun, 2021" }, { "code": null, "e": 24099, "s": 23948, "text": "Given a Sorted Array of n integers, and an Integer X, the task is to find whether the given Integer X appears more than n/2 times in the array or not." }, { ...
NumPy — The King of Scientific Computing with Python | by Shubhanshu Singh | Towards Data Science
Python is one of my favourite programming languages ( I love cpp too ). It is super easy to learn because of its beginner-friendly syntax. What makes it stand apart from the other programming language is its awesome developers' community. It comes pre-loaded with so many tools & libraries. And it is one of the most pre...
[ { "code": null, "e": 557, "s": 171, "text": "Python is one of my favourite programming languages ( I love cpp too ). It is super easy to learn because of its beginner-friendly syntax. What makes it stand apart from the other programming language is its awesome developers' community. It comes pre-loa...
Static Blocks in Java - GeeksforGeeks
02 Dec, 2021 In simpler language whenever we do uses a static keyword and associate it to a block then that block is referred to as a static block. Unlike C++, Java supports a special block, called a static block (also called static clause) that can be used for static initialization of a class. This code inside the sta...
[ { "code": null, "e": 19133, "s": 19105, "text": "\n02 Dec, 2021" }, { "code": null, "e": 19522, "s": 19133, "text": "In simpler language whenever we do uses a static keyword and associate it to a block then that block is referred to as a static block. Unlike C++, Java supports a ...
Check if elements of array can be made equal by multiplying given prime numbers - GeeksforGeeks
24 Mar, 2021 Given an array of integers and an array of prime numbers. The task is to find if it is possible to make all the elements of integer array equal by multiplying one or more elements from prime given array of prime numbers.Examples: Input : arr[] = {50, 200} prime[] = {2, 3} Output : Yes We can m...
[ { "code": null, "e": 24662, "s": 24634, "text": "\n24 Mar, 2021" }, { "code": null, "e": 24894, "s": 24662, "text": "Given an array of integers and an array of prime numbers. The task is to find if it is possible to make all the elements of integer array equal by multiplying one ...
Import Statement in Java
13 May, 2022 Import statement in Java is helpful to take a class or all classes visible for a program specified under a package, with the help of a single statement. It is pretty beneficial as the programmer do not require to write the entire class definition. Hence, it improves the readability of the program. This ar...
[ { "code": null, "e": 28, "s": 0, "text": "\n13 May, 2022" }, { "code": null, "e": 328, "s": 28, "text": "Import statement in Java is helpful to take a class or all classes visible for a program specified under a package, with the help of a single statement. It is pretty beneficia...
Components of Data Communication System
25 Jun, 2020 Data Communication is defined as exchange of data between two devices via some form of transmission media such as a cable, wire or it can be air or vacuum also. For occurrence of data communication, communicating devices must be a part of communication system made up of a combination of hardware or softwar...
[ { "code": null, "e": 53, "s": 25, "text": "\n25 Jun, 2020" }, { "code": null, "e": 384, "s": 53, "text": "Data Communication is defined as exchange of data between two devices via some form of transmission media such as a cable, wire or it can be air or vacuum also. For occurrenc...
Chain Rules - Online Quiz
Following quiz provides Multiple Choice Questions (MCQs) related to Chain Rules. You will have to read all the given answers and click over the correct answer. If you are not sure about the answer then you can check the answer using Show Answer button. You can use Next Quiz button to check new set of questions in the q...
[ { "code": null, "e": 4351, "s": 4026, "text": "Following quiz provides Multiple Choice Questions (MCQs) related to Chain Rules. You will have to read all the given answers and click over the correct answer. If you are not sure about the answer then you can check the answer using Show Answer button. ...
What is an Expression and What are the types of Expressions?
02 Aug, 2019 Expression: An expression is a combination of operators, constants and variables. An expression may consist of one or more operands, and zero or more operators to produce a value. Example: a+b c s-1/7*f . . etc Types of Expressions: Expressions may be of the following types: Constant expressions: Constant...
[ { "code": null, "e": 54, "s": 26, "text": "\n02 Aug, 2019" }, { "code": null, "e": 234, "s": 54, "text": "Expression: An expression is a combination of operators, constants and variables. An expression may consist of one or more operands, and zero or more operators to produce a v...
Java - pow() Method
The method returns the value of the first argument raised to the power of the second argument. double pow(double base, double exponent) Here is the detail of parameters − base − Any primitive data type. base − Any primitive data type. exponenet − Any primitive data type. exponenet − Any primitive data type. This metho...
[ { "code": null, "e": 2606, "s": 2511, "text": "The method returns the value of the first argument raised to the power of the second argument." }, { "code": null, "e": 2648, "s": 2606, "text": "double pow(double base, double exponent)\n" }, { "code": null, "e": 2683, ...
Reference and Copy Variables in JavaScript
08 Jul, 2022 In this article, we will talk about pass-by-value and pass-by-reference in JavaScript.JavaScript always passes by value, but in an array or object, the value is a reference to it, so you can ‘change’ the data. JavaScript has 5 primitive data types that are passed by value, they are Boolean, NULL, undefined...
[ { "code": null, "e": 28, "s": 0, "text": "\n08 Jul, 2022" }, { "code": null, "e": 660, "s": 28, "text": "In this article, we will talk about pass-by-value and pass-by-reference in JavaScript.JavaScript always passes by value, but in an array or object, the value is a reference to...
Replace all the NaN values with Zero’s in a column of a Pandas dataframe
25 Aug, 2021 Replacing the NaN or the null values in a dataframe can be easily performed using a single line DataFrame.fillna() and DataFrame.replace() method. We will discuss these methods along with an example demonstrating how to use it. This method is used to fill null or null values with a specific value. Syntax:...
[ { "code": null, "e": 28, "s": 0, "text": "\n25 Aug, 2021" }, { "code": null, "e": 257, "s": 28, "text": "Replacing the NaN or the null values in a dataframe can be easily performed using a single line DataFrame.fillna() and DataFrame.replace() method. We will discuss these metho...
Matplotlib.pyplot.ylabel() in Python
12 Apr, 2020 Matplotlib is a very powerful plotting library useful for those working with Python and NumPy. And for making statistical interference, it becomes very necessary to visualize our data and Matplotlib is the tool that can be very helpful for this purpose. This function sets the label for the y-axis of the pl...
[ { "code": null, "e": 28, "s": 0, "text": "\n12 Apr, 2020" }, { "code": null, "e": 282, "s": 28, "text": "Matplotlib is a very powerful plotting library useful for those working with Python and NumPy. And for making statistical interference, it becomes very necessary to visualize ...
Static methods vs Instance methods in Java
11 Feb, 2022 Instance Method Instance method are methods which require an object of its class to be created before it can be called. To invoke a instance method, we have to create an Object of the class in which the method is defined. public void geek(String name) { // code to be executed.... } // Return type can be ...
[ { "code": null, "e": 54, "s": 26, "text": "\n11 Feb, 2022" }, { "code": null, "e": 70, "s": 54, "text": "Instance Method" }, { "code": null, "e": 277, "s": 70, "text": "Instance method are methods which require an object of its class to be created before it ca...
Mathematics | Set Operations (Set theory)
05 Mar, 2021 Union of the sets A and B, denoted by A ∪ B, is the set of distinct elements that belong to set A or set B, or both. Venn diagram of A ∪ B Above is the Venn Diagram of A U B. Example: Find the union of A = {2, 3, 4} and B = {3, 4, 5}; Solution : A ∪ B = {2, 3, 4, 5}. The intersection of the sets A and B,...
[ { "code": null, "e": 52, "s": 24, "text": "\n05 Mar, 2021" }, { "code": null, "e": 170, "s": 52, "text": "Union of the sets A and B, denoted by A ∪ B, is the set of distinct elements that belong to set A or set B, or both. " }, { "code": null, "e": 192, "s": 170, ...
How to create Swipe Navigation in an Android App
01 Jun, 2020 When talking about Android Apps, the first thing that comes to mind is variety. There are so many varieties of Android apps providing the user with beautiful dynamic UI. One such feature is to navigate in our Android Apps using left and right swipes as opposed to clicking on buttons. Not only does it look ...
[ { "code": null, "e": 28, "s": 0, "text": "\n01 Jun, 2020" }, { "code": null, "e": 678, "s": 28, "text": "When talking about Android Apps, the first thing that comes to mind is variety. There are so many varieties of Android apps providing the user with beautiful dynamic UI. One s...
Training Neural Networks using Pytorch Lightning
26 Nov, 2020 Introduction: PyTorch Lightning is a library that provides a high-level interface for PyTorch. Problem with PyTorch is that every time you start a project you have to rewrite those training and testing loop. PyTorch Lightning fixes the problem by not only reducing boilerplate code but also providing added ...
[ { "code": null, "e": 52, "s": 24, "text": "\n26 Nov, 2020" }, { "code": null, "e": 66, "s": 52, "text": "Introduction:" }, { "code": null, "e": 729, "s": 66, "text": "PyTorch Lightning is a library that provides a high-level interface for PyTorch. Problem with...
Python | Column Mean in tuple list - GeeksforGeeks
15 Jan, 2022 Sometimes, while working with records, we can have a problem in which we need to average all the columns of a container of lists which are tuples. This kind of application is common in web development domain. Let’s discuss certain ways in which this task can be performed. Method #1 : Using sum() + list com...
[ { "code": null, "e": 24122, "s": 24094, "text": "\n15 Jan, 2022" }, { "code": null, "e": 24395, "s": 24122, "text": "Sometimes, while working with records, we can have a problem in which we need to average all the columns of a container of lists which are tuples. This kind of app...
Data Structures & Algorithms in Python | by Papa Moryba Kouate | Towards Data Science
To develop a complete mind: Study the science of art; Study the art of science. Learn how to see. Realize that everything connects to everything else. Leonardo da Vinci The purpose of this article is to give you a panorama of data structures and algorithms in Python. This topic is very important for a Data Scientist in...
[ { "code": null, "e": 323, "s": 172, "text": "To develop a complete mind: Study the science of art; Study the art of science. Learn how to see. Realize that everything connects to everything else." }, { "code": null, "e": 341, "s": 323, "text": "Leonardo da Vinci" }, { "co...
Java - URL Processing
URL stands for Uniform Resource Locator and represents a resource on the World Wide Web, such as a Web page or FTP directory. This section shows you how to write Java programs that communicate with a URL. A URL can be broken down into parts, as follows − protocol://host:port/path?query#ref Examples of protocols includ...
[ { "code": null, "e": 2503, "s": 2377, "text": "URL stands for Uniform Resource Locator and represents a resource on the World Wide Web, such as a Web page or FTP directory." }, { "code": null, "e": 2632, "s": 2503, "text": "This section shows you how to write Java programs that c...
Program to find sum of the sum of all contiguous sublists in Python
Suppose we have a list of numbers called nums, now consider every contiguous subarray. Sum each of these subarray and return the sum of all these values. Finally, mod the result by 10 ** 9 + 7. So, if the input is like nums = [3, 4, 6], then the output will be 43, as We have the following subarrays − [3] [4] [6] [3, 4]...
[ { "code": null, "e": 1256, "s": 1062, "text": "Suppose we have a list of numbers called nums, now consider every contiguous subarray. Sum each of these subarray and return the sum of all these values. Finally, mod the result by 10 ** 9 + 7." }, { "code": null, "e": 1431, "s": 1256, ...
Moving all special char to the end of the String using Java Regular Expression RegEx)
The following regular expression matches all the special characters i.e. all characters except English alphabet spaces and digits. "[^a-zA-Z0-9\\s+]" To move all the special characters to the end of the given line, match all the special characters using this regex concatenate them to an empty string and concatenate rem...
[ { "code": null, "e": 1193, "s": 1062, "text": "The following regular expression matches all the special characters i.e. all characters except English alphabet spaces and digits." }, { "code": null, "e": 1212, "s": 1193, "text": "\"[^a-zA-Z0-9\\\\s+]\"" }, { "code": null, ...
Angular 2 - Metadata
Metadata is used to decorate a class so that it can configure the expected behavior of the class. Following are the different parts for metadata. Annotations − These are decorators at the class level. This is an array and an example having both the @Component and @Routes decorator. Following is a sample code, which is ...
[ { "code": null, "e": 2443, "s": 2297, "text": "Metadata is used to decorate a class so that it can configure the expected behavior of the class. Following are the different parts for metadata." }, { "code": null, "e": 2580, "s": 2443, "text": "Annotations − These are decorators a...
D3.js - Array API
D3 contains a collection of modules. You can use each module independently or a collection of modules together to perform operations. This chapter explains about the Array API in detail. An Array contains a fixed-size sequential collection of elements of the same type. An array is used to store a collection of data, bu...
[ { "code": null, "e": 2317, "s": 2130, "text": "D3 contains a collection of modules. You can use each module independently or a collection of modules together to perform operations. This chapter explains about the Array API in detail." }, { "code": null, "e": 2544, "s": 2317, "tex...
Creating a C++ reusable Header File and its Implementation Files - GeeksforGeeks
08 Oct, 2021 Reusability is one of the most important concepts of Software Engineering. Reusability means developing code that can be reused either in the same program or in different programs. C++ allows reusability through inheritance, containership, polymorphism, and genericity. But, there is another way to define i...
[ { "code": null, "e": 24124, "s": 24096, "text": "\n08 Oct, 2021" }, { "code": null, "e": 24532, "s": 24124, "text": "Reusability is one of the most important concepts of Software Engineering. Reusability means developing code that can be reused either in the same program or in di...
How to get a list of installed Android applications in Kotlin?
This example demonstrates how to get a list of installed Android applications in Kotlin. 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": 1151, "s": 1062, "text": "This example demonstrates how to get a list of installed Android applications in Kotlin." }, { "code": null, "e": 1280, "s": 1151, "text": "Step 1 − Create a new project in Android Studio, go to File ? New Project and fill all requir...
execute_script driver method - Selenium Python - GeeksforGeeks
15 May, 2020 Selenium’s Python Module is built to perform automated testing with Python. Selenium Python bindings provides a simple API to write functional/acceptance tests using Selenium WebDriver. To open a webpage using Selenium Python, checkout – Navigating links using get method – Selenium Python.Just being able t...
[ { "code": null, "e": 24810, "s": 24782, "text": "\n15 May, 2020" }, { "code": null, "e": 25548, "s": 24810, "text": "Selenium’s Python Module is built to perform automated testing with Python. Selenium Python bindings provides a simple API to write functional/acceptance tests usi...
Android - Theme Demo Example
Following example demonstrates how you can use a theme for an application. For demo purpose we will modify our default AppTheme wehere default text, its size, family, shadow etc will be changed. Let's start with creating a simple Android application as per the following steps − Following is the content of the modified ...
[ { "code": null, "e": 3886, "s": 3607, "text": "Following example demonstrates how you can use a theme for an application. For demo purpose we will modify our default AppTheme wehere default text, its size, family, shadow etc will be changed. Let's start with creating a simple Android application as ...
[FIXED] Use -enable-preview to enable text blocks - onlinetutorialspoint
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 This article shows you how to enable preview ...
[ { "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, ...
AutoML for Time Series Forecasting | by Denis Vorotyntsev | Towards Data Science
Although I’m not a fan of nowadays AutoML, I enjoy participating in AutoML competitions. I believe that such competitions are a great learning opportunity and could give strong pipelines for future projects. AutoML competitions are something in between Kaggle-like competitions and LeetCode tasks: your code should give ...
[ { "code": null, "e": 538, "s": 171, "text": "Although I’m not a fan of nowadays AutoML, I enjoy participating in AutoML competitions. I believe that such competitions are a great learning opportunity and could give strong pipelines for future projects. AutoML competitions are something in between Ka...
Simulating stock prices in Python using Geometric Brownian Motion | by Umut Yildiz | Towards Data Science
It would be great if we can precisely predict how stock prices will change in near or far future. We would be rich, but it is almost impossible to create exact predictions. There are so many factors involved in the movement of stock prices that are hard to model. Human psychology is one of them. Investors, for sure, ma...
[ { "code": null, "e": 1006, "s": 172, "text": "It would be great if we can precisely predict how stock prices will change in near or far future. We would be rich, but it is almost impossible to create exact predictions. There are so many factors involved in the movement of stock prices that are hard ...
Maximum size square Sub-Matrix with sum less than or equals to K - GeeksforGeeks
19 Jul, 2021 Given a Matrix arr[][] of size M x N having positive integers and a number K, the task is to find the size of the largest square sub-matrix whose sum of elements is less than or equals to K. Example: Input: arr[][] = { { 1, 1, 3, 2, 4, 3, 2 }, { 1, 1, 3, 2, 4, 3, 2 }, { 1, 1, 3, ...
[ { "code": null, "e": 25288, "s": 25260, "text": "\n19 Jul, 2021" }, { "code": null, "e": 25480, "s": 25288, "text": "Given a Matrix arr[][] of size M x N having positive integers and a number K, the task is to find the size of the largest square sub-matrix whose sum of elements i...
Check if the given graph represents a Bus Topology - GeeksforGeeks
21 Feb, 2022 Given a graph G, check if it represents a Bus Topology.A Bus Topology is the one shown in the image below: Examples: Input: Output: YES Input: Output: NO A graph of V vertices represents a bus topology if it satisfies the following two conditions: Each node except the starting end ending ones ha...
[ { "code": null, "e": 26761, "s": 26733, "text": "\n21 Feb, 2022" }, { "code": null, "e": 26870, "s": 26761, "text": "Given a graph G, check if it represents a Bus Topology.A Bus Topology is the one shown in the image below: " }, { "code": null, "e": 26882, "s": 2...
PYGLET – Loading 3-D Model - GeeksforGeeks
06 Sep, 2021 In this article, we will see how we can load a 3-D model in PYGLET module in python. Pyglet is easy to use but powerful library for developing visually rich GUI applications like games, multimedia, etc. A window is a “heavyweight” object occupying operating system resources. Windows may appear as floating ...
[ { "code": null, "e": 24212, "s": 24184, "text": "\n06 Sep, 2021" }, { "code": null, "e": 25068, "s": 24212, "text": "In this article, we will see how we can load a 3-D model in PYGLET module in python. Pyglet is easy to use but powerful library for developing visually rich GUI ap...
C# | Gets an ICollection containing the values in the Hashtable - GeeksforGeeks
01 Feb, 2019 Hashtable.Values Property is used to get an ICollection containing the values in the Hashtable. Syntax: public virtual System.Collections.ICollection Values { get; } Return Value: This property returns an ICollection containing the values in the Hashtable. Note: The order of values in the ICollection is un...
[ { "code": null, "e": 24302, "s": 24274, "text": "\n01 Feb, 2019" }, { "code": null, "e": 24398, "s": 24302, "text": "Hashtable.Values Property is used to get an ICollection containing the values in the Hashtable." }, { "code": null, "e": 24406, "s": 24398, "te...
Input Pipeline for Images using Keras and TensorFlow | by Renu Khandelwal | Towards Data Science
Second, in the series to learn how to create an input pipeline to load and create image train and test dataset from custom data using Kera Preprocessing, Tensorflow, and tf.data. The dataset used here is Intel Image Classification from Kaggle, and all the code in the article works in Tensorflow 2.0. Intel Image classif...
[ { "code": null, "e": 351, "s": 172, "text": "Second, in the series to learn how to create an input pipeline to load and create image train and test dataset from custom data using Kera Preprocessing, Tensorflow, and tf.data." }, { "code": null, "e": 473, "s": 351, "text": "The dat...
Deep Learning meets Physics: Restricted Boltzmann Machines Part II | by Artem Oppermann | Towards Data Science
This article is the sequel of the first part where I introduced the theory behind Restricted Boltzmann Machines. This second part consists in a step by step guide through a practical implementation of a Restricted Boltzmann Machine which serves as a Recommender System and can predict whether a user would like a movie o...
[ { "code": null, "e": 524, "s": 172, "text": "This article is the sequel of the first part where I introduced the theory behind Restricted Boltzmann Machines. This second part consists in a step by step guide through a practical implementation of a Restricted Boltzmann Machine which serves as a Recom...
Jupyter notebook on AWS EC2 Instance | by Sanjay Singh | Towards Data Science
Jupyter is the most used development tool by data science and machine learning professionals. Considering most of the data science and machine learning projects involve working with data on the cloud, it makes sense to use the Jupyter notebook on the cloud. The flexibility of Jupyter on a ubiquitous cloud instance is a...
[ { "code": null, "e": 514, "s": 172, "text": "Jupyter is the most used development tool by data science and machine learning professionals. Considering most of the data science and machine learning projects involve working with data on the cloud, it makes sense to use the Jupyter notebook on the clou...
Compute the Sum of Rows of a Matrix or Array in R Programming - rowSums Function - GeeksforGeeks
03 Jun, 2020 rowSums() function in R Language is used to compute the sum of rows of a matrix or an array. Syntax: rowSums(x, na.rm = FALSE, dims = 1) Parameters:x: array or matrixdims: Integer: Dimensions are regarded as ‘rows’ to sum over. It is over dimensions dims+1, .... Example 1: # R program to illustrate# rowSum...
[ { "code": null, "e": 24843, "s": 24815, "text": "\n03 Jun, 2020" }, { "code": null, "e": 24936, "s": 24843, "text": "rowSums() function in R Language is used to compute the sum of rows of a matrix or an array." }, { "code": null, "e": 24980, "s": 24936, "text"...
Working with Python dictionaries: a cheat sheet | by Mahbubul Alam | Towards Data Science
Dictionaries in Python are a collection of key-value pairs — meaning every item in the dictionary has a key and an associated value. If we want to write down prices of some items in a grocery store, normally we will note them on a piece of paper like this: eggs - 4.99banana - 1.49cheese- 4.5eggplant - 2.5bread - 3.99 I...
[ { "code": null, "e": 305, "s": 172, "text": "Dictionaries in Python are a collection of key-value pairs — meaning every item in the dictionary has a key and an associated value." }, { "code": null, "e": 429, "s": 305, "text": "If we want to write down prices of some items in a gr...
Distinct permutations of a number - GeeksforGeeks
08 Jun, 2021 Given an integer N, the task is to print all distinct permutations of the number N. Examples: Input: N = 133Output: 133 313 331Explanation:There are a total of 6 permutations, which are [133, 313, 331, 133, 313, 331].Out of all these permutations, distinct permutations are [133, 313, 331]. Input: N = 7668O...
[ { "code": null, "e": 25061, "s": 25033, "text": "\n08 Jun, 2021" }, { "code": null, "e": 25145, "s": 25061, "text": "Given an integer N, the task is to print all distinct permutations of the number N." }, { "code": null, "e": 25155, "s": 25145, "text": "Exampl...
Python PostgreSQL - Insert Data
You can insert record into an existing table in PostgreSQL using the INSERT INTO statement. While executing this, you need to specify the name of the table, and values for the columns in it. Following is the recommended syntax of the INSERT statement − INSERT INTO TABLE_NAME (column1, column2, column3,...columnN) VALUE...
[ { "code": null, "e": 3396, "s": 3205, "text": "You can insert record into an existing table in PostgreSQL using the INSERT INTO statement. While executing this, you need to specify the name of the table, and values for the columns in it." }, { "code": null, "e": 3458, "s": 3396, ...
C program to remove extra spaces using string concepts.
Remove all the extra spaces from an entered string at runtime with the help of while loop by checking the spaces at each index of a character. Consider an example given below − It removes all the spaces from a given string. The given string is Tutorials Point C Programming. The result after removing spaces is Tutorials...
[ { "code": null, "e": 1205, "s": 1062, "text": "Remove all the extra spaces from an entered string at runtime with the help of while loop by checking the spaces at each index of a character." }, { "code": null, "e": 1239, "s": 1205, "text": "Consider an example given below −" },...
Hibernate - Many-to-One Mappings
A many-to-one association is the most common kind of association where an Object can be associated with multiple objects. For example, the same address object can be associated with multiple employee objects. Consider a situation where we need to store our employee records in EMPLOYEE table, which will have the followi...
[ { "code": null, "e": 2272, "s": 2063, "text": "A many-to-one association is the most common kind of association where an Object can be associated with multiple objects. For example, the same address object can be associated with multiple employee objects." }, { "code": null, "e": 2398, ...
Python | How to dynamically change text of Checkbutton - GeeksforGeeks
02 Apr, 2019 Tkinter is a GUI (Graphical User interface) module which is used to create various types of applications. It comes along with the Python and consists of various types of widgets which can be used to make GUI more attractive and user-friendly. Checkbutton is one of the widgets which is used to select multip...
[ { "code": null, "e": 24292, "s": 24264, "text": "\n02 Apr, 2019" }, { "code": null, "e": 24611, "s": 24292, "text": "Tkinter is a GUI (Graphical User interface) module which is used to create various types of applications. It comes along with the Python and consists of various ty...
Behave - Scenario Outlines
A Scenario Outline is used if we have a group of similar criteria and the results are to be passed in a Scenario. A Scenario Outline is accompanied with an Examples table. A Scenario Outline can have multiple Examples tables. The tests get executed once for every row found (after the header row) within the Examples tab...
[ { "code": null, "e": 2522, "s": 2296, "text": "A Scenario Outline is used if we have a group of similar criteria and the results are to be passed in a Scenario. A Scenario Outline is accompanied with an Examples table. A Scenario Outline can have multiple Examples tables." }, { "code": null,...
NumPy Array Slicing
Slicing in python means taking elements from one given index to another given index. We pass slice instead of index like this: [start:end]. We can also define the step, like this: [start:end:step]. If we don't pass start its considered 0 If we don't pass end its considered length of array in that dimension If we don't...
[ { "code": null, "e": 86, "s": 0, "text": "Slicing in python means taking elements from one given index to another given \nindex." }, { "code": null, "e": 141, "s": 86, "text": "We pass slice instead of index like this: [start:end]." }, { "code": null, "e": 199, "s...
Print concentric rectangular pattern in a 2d matrix in C++
In this problem, we have to print a rectangular pattern in a 2D matrix in such a way that they are concentric to each other. Let’s take an example to understand this problem better, For n=4 is : 4 4 4 4 4 4 4 4 3 3 3 3 3 4 4 3 2 2 2 3 4 4 3 2 1 2 3 4 4 3 2 2 2 3 4 4 3 3 3 3 3 4 4 4 4 4 4 4 4 Here, ...
[ { "code": null, "e": 1187, "s": 1062, "text": "In this problem, we have to print a rectangular pattern in a 2D matrix in such a way that they are concentric to each other." }, { "code": null, "e": 1244, "s": 1187, "text": "Let’s take an example to understand this problem better,"...
How to Querying Two Tables For Duplicate Values in SQL?
16 Nov, 2021 In this article, we will see how to write SQL queries to get duplicate values from two tables. We can perform the given task using two methods: Using INNER JOIN.Using WHERE clause Using INNER JOIN. Using WHERE clause Now, for the demonstration follow the below steps: Step 1: Create a database we can use th...
[ { "code": null, "e": 54, "s": 26, "text": "\n16 Nov, 2021" }, { "code": null, "e": 149, "s": 54, "text": "In this article, we will see how to write SQL queries to get duplicate values from two tables." }, { "code": null, "e": 198, "s": 149, "text": "We can per...
Remove all duplicates from a given string | Practice | GeeksforGeeks
Given a string Str which may contains lowercase and uppercase chracters. The task is to remove all duplicate characters from the string and find the resultant string. The order of remaining characters in the output should be same as in the original string. Example 1: Input: Str = geeksforgeeks Output: geksfor Explanati...
[ { "code": null, "e": 483, "s": 226, "text": "Given a string Str which may contains lowercase and uppercase chracters. The task is to remove all duplicate characters from the string and find the resultant string. The order of remaining characters in the output should be same as in the original string...
How to import a module in Typescript ?
19 Oct, 2021 Before starting with importing modules, first of all, we need to know the basics of modules in TypeScript. We know that JavaScript has come with the concept of modules from the ES6 version in 2015 and by 2020 had broad support in most web browsers and JavaScript runtimes. TypeScript also shares the same co...
[ { "code": null, "e": 54, "s": 26, "text": "\n19 Oct, 2021" }, { "code": null, "e": 161, "s": 54, "text": "Before starting with importing modules, first of all, we need to know the basics of modules in TypeScript." }, { "code": null, "e": 457, "s": 161, "text":...
PyQtGraph – Enable Mouse on Plot Window
01 Jun, 2021 In this article we will see how we can enable mouse on the plot window in the PyQtGraph module. PyQtGraph is a graphics and user interface library for Python that provides functionality commonly required in designing and science applications. Its primary goals are to provide fast, interactive graphics for ...
[ { "code": null, "e": 28, "s": 0, "text": "\n01 Jun, 2021" }, { "code": null, "e": 730, "s": 28, "text": "In this article we will see how we can enable mouse on the plot window in the PyQtGraph module. PyQtGraph is a graphics and user interface library for Python that provides fun...
Magical Indices in an array
03 Jun, 2021 Given an array A of integers. Index i of A is said to be connected to index j if j = (i + A[i]) % n + 1 (Assume 1-based indexing). Start traversing array from index i and jump to its next connected index. If on traversing array in the described order, index i is again visited then index i is a magical inde...
[ { "code": null, "e": 54, "s": 26, "text": "\n03 Jun, 2021" }, { "code": null, "e": 469, "s": 54, "text": "Given an array A of integers. Index i of A is said to be connected to index j if j = (i + A[i]) % n + 1 (Assume 1-based indexing). Start traversing array from index i and jum...
SQL Query to Find the Average Value in a Column
24 Mar, 2022 In this article, we are going to see how to find the average value in a column in SQL. A column in the SQL table is the vertical catalog structure. In this article, we will be using the Microsoft SQL Server as our database. For the purpose of example, we will be creating a sample table and performing the ...
[ { "code": null, "e": 53, "s": 25, "text": "\n24 Mar, 2022" }, { "code": null, "e": 278, "s": 53, "text": "In this article, we are going to see how to find the average value in a column in SQL. A column in the SQL table is the vertical catalog structure. In this article, we will ...
Node.js fs.opendir() Method
08 Oct, 2021 The fs.opendir() method is used to asynchronously open a directory in the file system. It creates an fs.Dir object that is used to represent the directory. This object contains various methods that can be used to accessing the directory. Syntax: fs.opendir( path[, options], callback ) Parameters: This meth...
[ { "code": null, "e": 28, "s": 0, "text": "\n08 Oct, 2021" }, { "code": null, "e": 266, "s": 28, "text": "The fs.opendir() method is used to asynchronously open a directory in the file system. It creates an fs.Dir object that is used to represent the directory. This object contain...
PostgreSQL – Reset Password For Postgres
22 Apr, 2022 In this article, we will look into the step-by-step process of resetting the Postgres user password in case the user forgets it. PostgreSQL uses the pg_hba.conf configuration file stored in the database data directory (e.g., C:\Program Files\PostgreSQL\12\data on Windows) and is used to handle user authent...
[ { "code": null, "e": 28, "s": 0, "text": "\n22 Apr, 2022" }, { "code": null, "e": 157, "s": 28, "text": "In this article, we will look into the step-by-step process of resetting the Postgres user password in case the user forgets it." }, { "code": null, "e": 400, ...
PyQt5 – Move the Label Position within the window using Arrow Keys
12 Jun, 2020 In this article we will see how we can move the label within the window using arrow keys i.e when ever the arrow key(direction key) get pressed it moves towards that direction. For example when user press the Up arrow key the label will move upward similarly for other arrow keys label will change its posit...
[ { "code": null, "e": 28, "s": 0, "text": "\n12 Jun, 2020" }, { "code": null, "e": 348, "s": 28, "text": "In this article we will see how we can move the label within the window using arrow keys i.e when ever the arrow key(direction key) get pressed it moves towards that direction...
D3.js selection.each() Function
18 Aug, 2020 The selection.each() function in D3.js is used to call the particular function for each selected HTML elements. In function datum(d) and index(i) are given as the parameters. By using this method one can access parent and child data simultaneously. Syntax: selection.each(callback); Parameters: This functi...
[ { "code": null, "e": 28, "s": 0, "text": "\n18 Aug, 2020" }, { "code": null, "e": 277, "s": 28, "text": "The selection.each() function in D3.js is used to call the particular function for each selected HTML elements. In function datum(d) and index(i) are given as the parameters. ...
Serialize and Deserialize JSON using GSON Library in Android
06 Dec, 2021 When we need to send some data from one activity to another, we can use intents with putExtra() function. But we putExtra supports primitive data types. So if we need to pass and the user defines the object, we need to serialize it first, then send it to the destination. While receiving the data we need to...
[ { "code": null, "e": 28, "s": 0, "text": "\n06 Dec, 2021" }, { "code": null, "e": 426, "s": 28, "text": "When we need to send some data from one activity to another, we can use intents with putExtra() function. But we putExtra supports primitive data types. So if we need to pass ...
Design Issues of Distributed System
29 Jun, 2022 Heterogeneity : Heterogeneity is applied to the network, computer hardware, operating system and implementation of different developers. A key component of the heterogeneous distributed system client-server environment is middleware. Middleware is a set of services that enables application and end-user to ...
[ { "code": null, "e": 28, "s": 0, "text": "\n29 Jun, 2022" }, { "code": null, "e": 2300, "s": 28, "text": "Heterogeneity : Heterogeneity is applied to the network, computer hardware, operating system and implementation of different developers. A key component of the heterogeneous ...
Internal and External Commands in Linux
03 Jul, 2020 The UNIX system is command-based i.e things happen because of the commands that you key in. All UNIX commands are seldom more than four characters long.They are grouped into two categories: Internal Commands : Commands which are built into the shell. For all the shell built-in commands, execution of the sa...
[ { "code": null, "e": 52, "s": 24, "text": "\n03 Jul, 2020" }, { "code": null, "e": 242, "s": 52, "text": "The UNIX system is command-based i.e things happen because of the commands that you key in. All UNIX commands are seldom more than four characters long.They are grouped into ...
How to make Range Slider and Selector in Plotly? - GeeksforGeeks
01 Oct, 2020 A Plotly is a Python library that is used to design graphs, especially interactive graphs. It can plot various graphs and charts like histogram, barplot, boxplot, spreadplot, and many more. It is mainly used in data analysis as well as financial analysis. plotly is an interactive visualization library. In ...
[ { "code": null, "e": 23524, "s": 23496, "text": "\n01 Oct, 2020" }, { "code": null, "e": 23828, "s": 23524, "text": "A Plotly is a Python library that is used to design graphs, especially interactive graphs. It can plot various graphs and charts like histogram, barplot, boxplot, ...
How to upload single/multiple image to cloudinary using node.js ? - GeeksforGeeks
20 Jan, 2022 Cloudinary is an end-to-end image and video management solution for websites and mobile apps, covering everything from image and video uploads, storage, manipulations, optimizations to delivery. Installation: Step 1: Go to the project directory and initialize the project using the below command in the term...
[ { "code": null, "e": 24922, "s": 24894, "text": "\n20 Jan, 2022" }, { "code": null, "e": 25117, "s": 24922, "text": "Cloudinary is an end-to-end image and video management solution for websites and mobile apps, covering everything from image and video uploads, storage, manipulati...
What are the rules for the Publisher interface in Java 9?
A Publisher is a provider of an unbounded number of sequenced elements publishing them according to demand received from its Subscribers. Publisher<T> interface is responsible for publishing elements of type T and provides a subscribe() method for subscribers to connect to it. public interface Publisher<T> { public ...
[ { "code": null, "e": 1340, "s": 1062, "text": "A Publisher is a provider of an unbounded number of sequenced elements publishing them according to demand received from its Subscribers. Publisher<T> interface is responsible for publishing elements of type T and provides a subscribe() method for subsc...
Support Vector Machine Python Example | by Cory Maklin | Towards Data Science
Support Vector Machine (SVM) is a supervised machine learning algorithm capable of performing classification, regression and even outlier detection. The linear SVM classifier works by drawing a straight line between two classes. All the data points that fall on one side of the line will be labeled as one class and all ...
[ { "code": null, "e": 938, "s": 47, "text": "Support Vector Machine (SVM) is a supervised machine learning algorithm capable of performing classification, regression and even outlier detection. The linear SVM classifier works by drawing a straight line between two classes. All the data points that fa...
Style Bootstrap 4 card with bg-success class
To set positive action to a card in Bootstrap, use the bg-success class with the card class Set positive action and use “card bg-success” − <div class="card bg-success text-white"> Now add the body of the card using the card-body class − <div class="card bg-success text-white"> <div class="card-body">India won by 7 w...
[ { "code": null, "e": 1154, "s": 1062, "text": "To set positive action to a card in Bootstrap, use the bg-success class with the card class" }, { "code": null, "e": 1202, "s": 1154, "text": "Set positive action and use “card bg-success” −" }, { "code": null, "e": 1243,...
Python program to sort a List according to the Length of the Elements?
Here we use one user input array and we have to sorted the list according to the length of the elements. Here we use Python inbuilt function sorted(). Input::[“mona”,”pp”,”aaa”] Lengths are [4,2,3] So, the sorted array should be [2,3,4] Output::[“pp”,”aaa”,”mona”] Step 1: Input list element. Step 2: apply sorted (A,le...
[ { "code": null, "e": 1213, "s": 1062, "text": "Here we use one user input array and we have to sorted the list according to the length of the elements. Here we use Python inbuilt function sorted()." }, { "code": null, "e": 1328, "s": 1213, "text": "Input::[“mona”,”pp”,”aaa”]\nLen...
Emergency vs Non-Emergency Vehicle Classification | by Venus Rohilla | Towards Data Science
Fatalities due to traffic delays of emergency vehicles such as ambulance & fire brigade is a huge problem. In daily life, we often see that emergency vehicles face difficulty in passing through traffic. So differentiating a vehicle into an emergency and non emergency category can be an important component in traffic mo...
[ { "code": null, "e": 608, "s": 172, "text": "Fatalities due to traffic delays of emergency vehicles such as ambulance & fire brigade is a huge problem. In daily life, we often see that emergency vehicles face difficulty in passing through traffic. So differentiating a vehicle into an emergency and n...
Calculate depth of a full Binary tree from Preorder - GeeksforGeeks
20 May, 2021 Given preorder of a binary tree, calculate its depth(or height) [starting from depth 0]. The preorder is given as a string with two possible characters. ‘l’ denotes the leaf‘n’ denotes internal node ‘l’ denotes the leaf ‘n’ denotes internal node The given tree can be seen as a full binary tree where every...
[ { "code": null, "e": 35848, "s": 35820, "text": "\n20 May, 2021" }, { "code": null, "e": 36002, "s": 35848, "text": "Given preorder of a binary tree, calculate its depth(or height) [starting from depth 0]. The preorder is given as a string with two possible characters. " }, {...
Python unittest - How to nicely mock a web crawler function? - GeeksforGeeks
01 Apr, 2021 Prerequisite: Python | Unit Test Objects Patching Unit Testing is the first level of software testing where the smallest testable parts of the software are tested. This is used to validate that each unit of the software performs as designed. The Unittest framework is python’s xUnit style framework. Before ...
[ { "code": null, "e": 24292, "s": 24264, "text": "\n01 Apr, 2021" }, { "code": null, "e": 24342, "s": 24292, "text": "Prerequisite: Python | Unit Test Objects Patching" }, { "code": null, "e": 24699, "s": 24342, "text": "Unit Testing is the first level of softw...