title stringlengths 3 221 | text stringlengths 17 477k | parsed listlengths 0 3.17k |
|---|---|---|
Multiprocessing In Python | The multiprocessing package supports spawning processes. It refers to a function that loads and executes a new child processes. For the child to terminate or to continue executing concurrent computing,then the current process hasto wait using an API, which is similar to threading module.
When we work with Multiprocessi... | [
{
"code": null,
"e": 1351,
"s": 1062,
"text": "The multiprocessing package supports spawning processes. It refers to a function that loads and executes a new child processes. For the child to terminate or to continue executing concurrent computing,then the current process hasto wait using an API, wh... |
Bringing Colab to a Jupyter Notebook near you... | by Robert Dargavel Smith | Towards Data Science | When programming in Python, it can be quite overwhelming when you hit an error deep down in a stack of nested function calls. One of the advantages of Python is that it has an enormous amount of high quality libraries available and for which the source code is readily available. Sometimes, it is useful just to be able ... | [
{
"code": null,
"e": 560,
"s": 172,
"text": "When programming in Python, it can be quite overwhelming when you hit an error deep down in a stack of nested function calls. One of the advantages of Python is that it has an enormous amount of high quality libraries available and for which the source co... |
C# | Tuple | 30 Apr, 2019
The word Tuple means “a data structure which consists of the multiple parts”. So tuple is a data structure which gives you the easiest way to represent a data set which has multiple values that may/may not be related to each other. It introduced in .NET Framework 4.0. In tuple, you can add elements from 1 ... | [
{
"code": null,
"e": 53,
"s": 25,
"text": "\n30 Apr, 2019"
},
{
"code": null,
"e": 619,
"s": 53,
"text": "The word Tuple means “a data structure which consists of the multiple parts”. So tuple is a data structure which gives you the easiest way to represent a data set which has m... |
Optimization techniques for Gradient Descent | 20 Jun, 2022
Gradient Descent is an iterative optimization algorithm, used to find the minimum value for a function. The general idea is to initialize the parameters to random values, and then take small steps in the direction of the “slope” at each iteration. Gradient descent is highly used in supervised learning to m... | [
{
"code": null,
"e": 54,
"s": 26,
"text": "\n20 Jun, 2022"
},
{
"code": null,
"e": 545,
"s": 54,
"text": "Gradient Descent is an iterative optimization algorithm, used to find the minimum value for a function. The general idea is to initialize the parameters to random values, and... |
PyQt5 | How to create colorful border of Push Button ? | 22 Apr, 2020
In this article we will see how to create colorful border of Push button. By default, push button have a button but we can also change the border color and size as well. PyQt5 allows us to change the color of push button with the help of style sheet.
Syntax :
button.setStyleSheet("border :5px solid ;"
... | [
{
"code": null,
"e": 53,
"s": 25,
"text": "\n22 Apr, 2020"
},
{
"code": null,
"e": 304,
"s": 53,
"text": "In this article we will see how to create colorful border of Push button. By default, push button have a button but we can also change the border color and size as well. PyQt... |
Python | Pandas dataframe.subtract() | 22 Sep, 2021
Python is a great language for doing data analysis, primarily because of the fantastic ecosystem of data-centric python packages. Pandas is one of those packages and makes importing and analyzing data much easier.
Pandas dataframe.subtract() function is used for finding the subtraction of dataframe and oth... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n22 Sep, 2021"
},
{
"code": null,
"e": 242,
"s": 28,
"text": "Python is a great language for doing data analysis, primarily because of the fantastic ecosystem of data-centric python packages. Pandas is one of those packages and makes imp... |
Identifiers in Go Language | 18 Nov, 2019
In programming languages, identifiers are used for identification purposes. Or in other words, identifiers are the user-defined name of the program components. In Go language, an identifier can be a variable name, function name, constant, statement labels, package name, or types.
Example:
package main
impo... | [
{
"code": null,
"e": 53,
"s": 25,
"text": "\n18 Nov, 2019"
},
{
"code": null,
"e": 334,
"s": 53,
"text": "In programming languages, identifiers are used for identification purposes. Or in other words, identifiers are the user-defined name of the program components. In Go language... |
Mongoose | exists() Function | 21 May, 2020
The exists() function returns true if at least one document exists in the database that matches the given filter, and false otherwise.
Installation of mongoose module:
You can visit the link to Install mongoose module. You can install this package by using this command.npm install mongooseAfter installing ... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n21 May, 2020"
},
{
"code": null,
"e": 163,
"s": 28,
"text": "The exists() function returns true if at least one document exists in the database that matches the given filter, and false otherwise."
},
{
"code": null,
"e": 196... |
Recover in Golang | 17 Sep, 2019
Just like try/catch block in exception in languages like Java, C#, etc. are used to catch exception similarly in Go language, recover function is used to handle panic. It is an inbuilt function which is defined under the builtin package of the Go language. The main use of this function is to regain control... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n17 Sep, 2019"
},
{
"code": null,
"e": 433,
"s": 28,
"text": "Just like try/catch block in exception in languages like Java, C#, etc. are used to catch exception similarly in Go language, recover function is used to handle panic. It is a... |
Docker - Toolbox | In the introductory chapters, we have seen the installation of Docker toolbox on Windows. The Docker toolbox is developed so that Docker containers can be run on Windows and MacOS. The site for toolbox on Windows is https://docs.docker.com/docker-for-windows/
For Windows, you need to have Windows 10 or Windows Server 2... | [
{
"code": null,
"e": 2734,
"s": 2474,
"text": "In the introductory chapters, we have seen the installation of Docker toolbox on Windows. The Docker toolbox is developed so that Docker containers can be run on Windows and MacOS. The site for toolbox on Windows is https://docs.docker.com/docker-for-wi... |
How to Remove the First Characters of a Specific Column in a Table in SQL? | 08 Oct, 2021
Here we will see, how to remove the first characters of a specific column in a table in SQL. We can do this task using the String function.
String functions are used to perform an operation on an input string and return an output string. There are various string functions like LEN(for SQL server), SUBSTR,... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n08 Oct, 2021"
},
{
"code": null,
"e": 169,
"s": 28,
"text": "Here we will see, how to remove the first characters of a specific column in a table in SQL. We can do this task using the String function. "
},
{
"code": null,
"e... |
Ulimit, Soft Limits and Hard Limits in Linux | 26 Nov, 2020
ulimit is admin access required Linux shell command which is used to see, set, or limit the resource usage of the current user. It is used to return the number of open file descriptors for each process. It is also used to set restrictions on the resources used by a process.
Syntax:
To check the ulimit valu... | [
{
"code": null,
"e": 53,
"s": 25,
"text": "\n26 Nov, 2020"
},
{
"code": null,
"e": 328,
"s": 53,
"text": "ulimit is admin access required Linux shell command which is used to see, set, or limit the resource usage of the current user. It is used to return the number of open file d... |
Program to implement Singly Linked List in C++ using class | 03 Jul, 2022
The linked list stores data in sequential storage, like arrays. Though the data are stored sequentially, the memory locations are not contiguous.Unlike an array, the linked list can store data of different data types.The below diagram represents the linked-list structure.
In C++ the linked list can be rep... | [
{
"code": null,
"e": 52,
"s": 24,
"text": "\n03 Jul, 2022"
},
{
"code": null,
"e": 326,
"s": 52,
"text": "The linked list stores data in sequential storage, like arrays. Though the data are stored sequentially, the memory locations are not contiguous.Unlike an array, the linked l... |
Difference between Tuple Relational Calculus (TRC) and Domain Relational Calculus (DRC) | 07 Jun, 2022
1. Tuple Relational Calculus (TRC) : A tuple relational calculus is a non-procedural query language that specifies to select of the tuples in a relation. It can select the tuples with a range of values or tuples for certain attribute values etc. The resulting relation can have one or more tuples.
Notation... | [
{
"code": null,
"e": 53,
"s": 25,
"text": "\n07 Jun, 2022"
},
{
"code": null,
"e": 352,
"s": 53,
"text": "1. Tuple Relational Calculus (TRC) : A tuple relational calculus is a non-procedural query language that specifies to select of the tuples in a relation. It can select the tu... |
Introduction to NSE Tools Module in Python | 03 Aug, 2021
NSE National Stock Exchange of India Limited is the leading stock exchange of India, located in Mumbai, Maharashtra. NSE was established in 1992 as the first dematerialized electronic exchange in the country.nsetools is a library for collecting real time data from National Stock Exchange of India. It can b... | [
{
"code": null,
"e": 53,
"s": 25,
"text": "\n03 Aug, 2021"
},
{
"code": null,
"e": 815,
"s": 53,
"text": "NSE National Stock Exchange of India Limited is the leading stock exchange of India, located in Mumbai, Maharashtra. NSE was established in 1992 as the first dematerialized e... |
Square root of an integer | 23 Jun, 2022
Given an integer x, find it’s square root. If x is not a perfect square, then return floor(√x).
Examples :
Input: x = 4
Output: 2
Explanation: The square root of 4 is 2.
Input: x = 11
Output: 3
Explanation: The square root of 11 lies in between
3 and 4 so floor of the square root is 3.
There can be man... | [
{
"code": null,
"e": 52,
"s": 24,
"text": "\n23 Jun, 2022"
},
{
"code": null,
"e": 148,
"s": 52,
"text": "Given an integer x, find it’s square root. If x is not a perfect square, then return floor(√x)."
},
{
"code": null,
"e": 160,
"s": 148,
"text": "Examples ... |
Static Function in PHP | 31 Jul, 2021
In certain cases, it is very handy to access methods and properties in terms of a class rather than an object. This can be done with the help of static keyword. Any method declared as static is accessible without the creation of an object. Static functions are associated with the class, not an instance of ... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n31 Jul, 2021"
},
{
"code": null,
"e": 478,
"s": 28,
"text": "In certain cases, it is very handy to access methods and properties in terms of a class rather than an object. This can be done with the help of static keyword. Any method dec... |
WPF - WrapPanel | In WrapPanel, child elements are positioned in sequential order, from left to right or from top to bottom based on the orientation property. The only difference between StackPanel and WrapPanel is that it doesn’t stack all the child elements in a single line; it wraps the remaining elements to another line if there is ... | [
{
"code": null,
"e": 2489,
"s": 2154,
"text": "In WrapPanel, child elements are positioned in sequential order, from left to right or from top to bottom based on the orientation property. The only difference between StackPanel and WrapPanel is that it doesn’t stack all the child elements in a single... |
Principal Component Analysis with R Programming | 16 Dec, 2021
Principal component analysis(PCA) in R programming is an analysis of the linear components of all existing attributes. Principal components are linear combinations (orthogonal transformation) of the original predictor in the dataset. It is a useful technique for EDA(Exploratory data analysis) and allows yo... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n16 Dec, 2021"
},
{
"code": null,
"e": 414,
"s": 28,
"text": "Principal component analysis(PCA) in R programming is an analysis of the linear components of all existing attributes. Principal components are linear combinations (orthogonal... |
turtle.forward() method in Python-Turtle | 16 Jul, 2020
The turtle module provides turtle graphics primitives, in both object-oriented and procedure-oriented ways. Because it uses Tkinter for the underlying graphics, it needs a version of Python installed with Tk support.
The turtle.forward() method is used to move the turtle forward by the value of the argumen... | [
{
"code": null,
"e": 53,
"s": 25,
"text": "\n16 Jul, 2020"
},
{
"code": null,
"e": 270,
"s": 53,
"text": "The turtle module provides turtle graphics primitives, in both object-oriented and procedure-oriented ways. Because it uses Tkinter for the underlying graphics, it needs a ve... |
Working with XML Files in R Programming | 13 Sep, 2021
XML which stands for Extensible Markup Language is made up of markup tags, wherein each tag illustrates the information carried by the particular attribute in the XML file. We can work with the XML files using the XML package provided by R. The package has to be explicitly installed using the following com... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n13 Sep, 2021"
},
{
"code": null,
"e": 342,
"s": 28,
"text": "XML which stands for Extensible Markup Language is made up of markup tags, wherein each tag illustrates the information carried by the particular attribute in the XML file. We... |
Accessing Data in a MultiIndex DataFrame in Pandas | by B. Chen | Towards Data Science | A MultiIndex (also known as a hierarchical index) DataFrame allows you to have multiple columns acting as a row identifier and multiple rows acting as a header identifier. With MultiIndex, you can do some sophisticated data analysis, especially for working with higher dimensional data. Accessing data is the first step ... | [
{
"code": null,
"e": 532,
"s": 172,
"text": "A MultiIndex (also known as a hierarchical index) DataFrame allows you to have multiple columns acting as a row identifier and multiple rows acting as a header identifier. With MultiIndex, you can do some sophisticated data analysis, especially for workin... |
Tryit Editor v3.7 | Tryit: Using pseudo-element and HTML class | [] |
Java default Keyword | ❮ Java Keywords
Specify some code to run if there is no case match in a switch block:
int day = 4;
switch (day) {
case 6:
System.out.println("Today is Saturday");
break;
case 7:
System.out.println("Today is Sunday");
break;
default:
System.out.println("Looking forward to the Weekend");
}
/ Ou... | [
{
"code": null,
"e": 18,
"s": 0,
"text": "\n❮ Java Keywords\n"
},
{
"code": null,
"e": 88,
"s": 18,
"text": "Specify some code to run if there is no case match in a switch block:"
},
{
"code": null,
"e": 361,
"s": 88,
"text": "int day = 4;\nswitch (day) {\n c... |
C++ Program to print an Array using Recursion - GeeksforGeeks | 11 Oct, 2019
Write a program in C++ to print an Array using Recursion
Using static variable: Static variables have a property of preserving their value even after they are out of their scope! Hence, static variables preserve their previous value in their previous scope and are not initialized again in the new scope.Syn... | [
{
"code": null,
"e": 24429,
"s": 24401,
"text": "\n11 Oct, 2019"
},
{
"code": null,
"e": 24486,
"s": 24429,
"text": "Write a program in C++ to print an Array using Recursion"
},
{
"code": null,
"e": 25954,
"s": 24486,
"text": "Using static variable: Static var... |
How to Set Up a Foreign Data Wrapper in PostgreSQL | by Eve Ben Ezra | Towards Data Science | A foreign data wrapper is an extension available in PostgreSQL that allows you to access a table or schema in one database from another. Foreign data wrappers can serve all sorts of purposes:
Completing a data flow cycle
Your data may be segregated across databases, but still related in ways that makes being able to co... | [
{
"code": null,
"e": 364,
"s": 172,
"text": "A foreign data wrapper is an extension available in PostgreSQL that allows you to access a table or schema in one database from another. Foreign data wrappers can serve all sorts of purposes:"
},
{
"code": null,
"e": 393,
"s": 364,
"te... |
OpenNLP - Tokenization | The process of chopping the given sentence into smaller parts (tokens) is known as tokenization. In general, the given raw text is tokenized based on a set of delimiters (mostly whitespaces).
Tokenization is used in tasks such as spell-checking, processing searches, identifying parts of speech, sentence detection, docu... | [
{
"code": null,
"e": 2044,
"s": 1852,
"text": "The process of chopping the given sentence into smaller parts (tokens) is known as tokenization. In general, the given raw text is tokenized based on a set of delimiters (mostly whitespaces)."
},
{
"code": null,
"e": 2211,
"s": 2044,
... |
Form validation using HTML and JavaScript - GeeksforGeeks | 28 Jul, 2021
Forms are used in webpages for the user to enter their required details that further send it to the server for processing. A form is also known as a web form or HTML form. Examples of form use are prevalent in e-commerce websites, online banking, online surveys to name a few.
Syntax for form in HTML
<body>... | [
{
"code": null,
"e": 30082,
"s": 30054,
"text": "\n28 Jul, 2021"
},
{
"code": null,
"e": 30359,
"s": 30082,
"text": "Forms are used in webpages for the user to enter their required details that further send it to the server for processing. A form is also known as a web form or HT... |
Compute Beta Distribution in R Programming - dbeta(), pbeta(), qbeta(), and rbeta() Functions - GeeksforGeeks | 23 Jun, 2020
Beta Distribution in R Language is defined as property which represents the possible values of probability. This article is an illustration of dbeta, pbeta, qbeta, and rbeta functions of Beta Distribution.
It is defined as Beta Density function and is used to create beta density value corresponding to the ... | [
{
"code": null,
"e": 25043,
"s": 25015,
"text": "\n23 Jun, 2020"
},
{
"code": null,
"e": 25249,
"s": 25043,
"text": "Beta Distribution in R Language is defined as property which represents the possible values of probability. This article is an illustration of dbeta, pbeta, qbeta,... |
6 Key differences between np.ndarray and np.matrix objects | by Rukshan Pramoditha | Towards Data Science | Numpy is the foundational Python library that is widely used for numerical calculations and linear algebra. ndarray and matrix objects are commonly used numpy objects. ndarray objects are created from the numpy ndarray class. matrix objects are created from the numpy matrix class. If you’re new to numpy, you may get co... | [
{
"code": null,
"e": 670,
"s": 171,
"text": "Numpy is the foundational Python library that is widely used for numerical calculations and linear algebra. ndarray and matrix objects are commonly used numpy objects. ndarray objects are created from the numpy ndarray class. matrix objects are created fr... |
Java Generics - Classes | A generic class declaration looks like a non-generic class declaration, except that the class name is followed by a type parameter section.
The type parameter section of a generic class can have one or more type parameters separated by commas. These classes are known as parameterized classes or parameterized types beca... | [
{
"code": null,
"e": 2780,
"s": 2640,
"text": "A generic class declaration looks like a non-generic class declaration, except that the class name is followed by a type parameter section."
},
{
"code": null,
"e": 3000,
"s": 2780,
"text": "The type parameter section of a generic cl... |
Intro to NLTK for NLP with Python - Tokenization, Stopwords, Stemming, and PoS Tagging | Towards Data Science | NLTK (Natural Language Toolkit) is the go-to API for NLP (Natural Language Processing) with Python. It is a really powerful tool to preprocess text data for further analysis like with ML models for instance. It helps convert text into numbers, which the model can then easily work with. This is the first part of a basic... | [
{
"code": null,
"e": 584,
"s": 172,
"text": "NLTK (Natural Language Toolkit) is the go-to API for NLP (Natural Language Processing) with Python. It is a really powerful tool to preprocess text data for further analysis like with ML models for instance. It helps convert text into numbers, which the m... |
Django for Data Scientists — An Introduction to Django and Django’s ORM | by Dominik Polzer | Towards Data Science | The extensive feature set of Django as a high-level Web framework can scare off Data Analysts and Data Scientists who never really had contact with Web development. Unfortunately, this could keep them from experiencing Django’s impressive and easy to use Data Management abilities.
While the most Django tutorials cover ... | [
{
"code": null,
"e": 328,
"s": 46,
"text": "The extensive feature set of Django as a high-level Web framework can scare off Data Analysts and Data Scientists who never really had contact with Web development. Unfortunately, this could keep them from experiencing Django’s impressive and easy to use D... |
Private and Protected Members in C++ | A class in C++ has public, private and protected sections which contain the corresponding class members.
The private data members cannot be accessed from outside the class. They can only be accessed by class or friend functions. All the class members are private by default.
The protected members in a class are similar ... | [
{
"code": null,
"e": 1167,
"s": 1062,
"text": "A class in C++ has public, private and protected sections which contain the corresponding class members."
},
{
"code": null,
"e": 1337,
"s": 1167,
"text": "The private data members cannot be accessed from outside the class. They can ... |
Python | Pandas dataframe.sum() - GeeksforGeeks | 22 Oct, 2019
Python is a great language for doing data analysis, primarily because of the fantastic ecosystem of data-centric python packages. Pandas is one of those packages and makes importing and analyzing data much easier.
Pandas dataframe.sum() function return the sum of the values for the requested axis. If the i... | [
{
"code": null,
"e": 24984,
"s": 24956,
"text": "\n22 Oct, 2019"
},
{
"code": null,
"e": 25198,
"s": 24984,
"text": "Python is a great language for doing data analysis, primarily because of the fantastic ecosystem of data-centric python packages. Pandas is one of those packages a... |
Violinplot using Seaborn in Python - GeeksforGeeks | 15 Jan, 2022
Seaborn is an amazing visualization library for statistical graphics plotting in Python. It provides beautiful default styles and color palettes to make statistical plots more attractive. It is built on the top of matplotlib library and also closely integrated into the data structures from pandas.
A violin... | [
{
"code": null,
"e": 28117,
"s": 28089,
"text": "\n15 Jan, 2022"
},
{
"code": null,
"e": 28416,
"s": 28117,
"text": "Seaborn is an amazing visualization library for statistical graphics plotting in Python. It provides beautiful default styles and color palettes to make statistica... |
Cube - CUBEVALUE Function | The CUBEVALUE function returns an aggregated value from the cube.
CUBEVALUE (connection, [member_expression1], [member_expression2], ...)
A text string of a multidimensional expression (MDX) that evaluates to a member or tuple within the cube.
OR
A set defined with the CUBESET function.
Use the Argument member_express... | [
{
"code": null,
"e": 1920,
"s": 1854,
"text": "The CUBEVALUE function returns an aggregated value from the cube."
},
{
"code": null,
"e": 1993,
"s": 1920,
"text": "CUBEVALUE (connection, [member_expression1], [member_expression2], ...)\n"
},
{
"code": null,
"e": 2099,... |
Random Forests and the Bias-Variance Tradeoff | by Prratek Ramchandani | Towards Data Science | The Random Forest is an extremely popular machine learning algorithm. Often, with not too much pre-processing, one can throw together a quick and dirty model with no hyperparameter tuning and acheive results that aren’t awful. As an example, I put together a RandomForestRegressor in Python using scikit-learn for the Ne... | [
{
"code": null,
"e": 724,
"s": 172,
"text": "The Random Forest is an extremely popular machine learning algorithm. Often, with not too much pre-processing, one can throw together a quick and dirty model with no hyperparameter tuning and acheive results that aren’t awful. As an example, I put togethe... |
Set Button on Image with CSS | You can try to run the following code to set button on an image:
Live Demo
<!DOCTYPE html>
<html>
<head>
<style>
.box {
position: relative;
width: 100%;
max-width: 250px;
}
.box img {
width: 100%;
height: auto;
}
... | [
{
"code": null,
"e": 1127,
"s": 1062,
"text": "You can try to run the following code to set button on an image:"
},
{
"code": null,
"e": 1137,
"s": 1127,
"text": "Live Demo"
},
{
"code": null,
"e": 1801,
"s": 1137,
"text": "<!DOCTYPE html>\n<html>\n <head>\n... |
How to Save Data to the Firebase Realtime Database in Android? | 31 Dec, 2020
Firebase is one of the famous backend platforms which is used by so many developers to provide backend support to their applications and websites. It is the product of Google which provides services such as database, storage, user authentication, and many more. In this article, we will create a simple app ... | [
{
"code": null,
"e": 54,
"s": 26,
"text": "\n31 Dec, 2020"
},
{
"code": null,
"e": 503,
"s": 54,
"text": "Firebase is one of the famous backend platforms which is used by so many developers to provide backend support to their applications and websites. It is the product of Google... |
UPI Payment Integration in Android | 14 Dec, 2021
If you are selling any product or providing any service in your android application, then you should have integrated a feature in your android application where you can allow users to make payment through your application. In this article, we will take a look at the implementation of payment gateway integr... | [
{
"code": null,
"e": 54,
"s": 26,
"text": "\n14 Dec, 2021"
},
{
"code": null,
"e": 476,
"s": 54,
"text": "If you are selling any product or providing any service in your android application, then you should have integrated a feature in your android application where you can allow... |
SVG stroke-dasharray Attribute | 31 Mar, 2022
The stroke-dasharray attribute is a presentation attribute defining the pattern of dashes used to paint the outline of the shape.
Syntax:
stroke-dasharray="number pattern"
Attribute Values:
dasharray: The pattern stroke that will have.
We will use the stoke-dasharray attribute for setting the pattern of th... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n31 Mar, 2022"
},
{
"code": null,
"e": 158,
"s": 28,
"text": "The stroke-dasharray attribute is a presentation attribute defining the pattern of dashes used to paint the outline of the shape."
},
{
"code": null,
"e": 166,
... |
deleteLater() method in PyQt5 | 26 Mar, 2020
While designing an application it could potentially consume a lot of space/memory if care is not taken when closing widgets. The QObject-based classes are designed to be (optionally) linked together in a hierarchy. When a top-level object is deleted, Qt will automatically delete all its child objects as we... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n26 Mar, 2020"
},
{
"code": null,
"e": 489,
"s": 28,
"text": "While designing an application it could potentially consume a lot of space/memory if care is not taken when closing widgets. The QObject-based classes are designed to be (opti... |
Graph Plotting in Python | Set 3 | 09 Feb, 2018
Graph Plotting in Python | Set 1Graph Plotting in Python | Set 2
Matplotlib is a pretty extensive library which supports Animations of graphs as well. The animation tools center around the matplotlib.animation base class, which provides a framework around which the animation functionality is built. The mai... | [
{
"code": null,
"e": 53,
"s": 25,
"text": "\n09 Feb, 2018"
},
{
"code": null,
"e": 118,
"s": 53,
"text": "Graph Plotting in Python | Set 1Graph Plotting in Python | Set 2"
},
{
"code": null,
"e": 479,
"s": 118,
"text": "Matplotlib is a pretty extensive library... |
maketrans() and translate() functions in Python | 15 Oct, 2020
In the world of programming, seldom there is a need to replace all the words/characters at once in the whole file python offers this functionality using functions translate() and its helper functions maketrans(). Both functions are discussed in this article.
maketrans() function is used to construct the tr... | [
{
"code": null,
"e": 52,
"s": 24,
"text": "\n15 Oct, 2020"
},
{
"code": null,
"e": 311,
"s": 52,
"text": "In the world of programming, seldom there is a need to replace all the words/characters at once in the whole file python offers this functionality using functions translate()... |
Namechk – Osint tool for Usernames | 23 Aug, 2021
Namechk is an osint tool that is based on namechk.com and is used for checking usernames on more than 100 websites, forums, and social networks. What if there is a tool that can tell whether a username you want is available or not on multiple platforms or not. Yes, you read it right, Namechk can do this wi... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n23 Aug, 2021"
},
{
"code": null,
"e": 440,
"s": 28,
"text": "Namechk is an osint tool that is based on namechk.com and is used for checking usernames on more than 100 websites, forums, and social networks. What if there is a tool that c... |
Random Forest Regression in Python | 16 May, 2022
Every decision tree has high variance, but when we combine all of them together in parallel then the resultant variance is low as each decision tree gets perfectly trained on that particular sample data, and hence the output doesn’t depend on one decision tree but on multiple decision trees. In the case of... | [
{
"code": null,
"e": 54,
"s": 26,
"text": "\n16 May, 2022"
},
{
"code": null,
"e": 575,
"s": 54,
"text": "Every decision tree has high variance, but when we combine all of them together in parallel then the resultant variance is low as each decision tree gets perfectly trained on... |
Python | How to Concatenate tuples to nested tuples | 21 Nov, 2019
Sometimes, while working with tuples, we can have a problem in which we need to convert individual records into a nested collection yet remaining as separate element. Usual addition of tuples, generally adds the contents and hence flattens the resultant container, this is usually undesired. Let’s discuss c... | [
{
"code": null,
"e": 54,
"s": 26,
"text": "\n21 Nov, 2019"
},
{
"code": null,
"e": 406,
"s": 54,
"text": "Sometimes, while working with tuples, we can have a problem in which we need to convert individual records into a nested collection yet remaining as separate element. Usual a... |
MATLAB | Display histogram of a grayscale Image | 26 Jan, 2019
An image histogram is chart representation of the distribution of intensities in an Indexed image or grayscale image. It shows how many times each intensity value in image occurs.
Code #1: Display histogram of an image using MATLAB library function.
% Read an Image in MATLAB Environmentimg=imread('apple.jp... | [
{
"code": null,
"e": 54,
"s": 26,
"text": "\n26 Jan, 2019"
},
{
"code": null,
"e": 234,
"s": 54,
"text": "An image histogram is chart representation of the distribution of intensities in an Indexed image or grayscale image. It shows how many times each intensity value in image oc... |
Flutter – Social Media Authentication Buttons | 15 Feb, 2021
Customizing an application for a better user experience requires data storage of each individual user based on their preferences and interests. But profiling each and every user can be tedious. This is where social media authentication comes into play. These authentication systems not only reduce the hect... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n15 Feb, 2021"
},
{
"code": null,
"e": 520,
"s": 28,
"text": "Customizing an application for a better user experience requires data storage of each individual user based on their preferences and interests. But profiling each and every us... |
How to find the index value of specified string in Golang? | 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 strings, you can find the first index value of the specified string from the or... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n26 Aug, 2019"
},
{
"code": null,
"e": 515,
"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... |
How to work with Julia on Jupyter Notebook? | 14 Sep, 2021
Julia is a programming language that uses multiple dispatches as a feature where a method or a function can be dynamically dispatched based on the requirement. It is a high performance and a dynamic language which makes it user-interactive. It has a high-level syntax which makes it easy to learn and use fo... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n14 Sep, 2021"
},
{
"code": null,
"e": 432,
"s": 28,
"text": "Julia is a programming language that uses multiple dispatches as a feature where a method or a function can be dynamically dispatched based on the requirement. It is a high pe... |
Rank of an element in a stream | 01 Jul, 2021
Given a stream of integers, lookup the rank of a given integer x. Rank of an integer in-stream is “Total number of elements less than or equal to x (not including x)”.If an element is not found in the stream or is smallest in stream, return -1. Examples:
Input : arr[] = {10, 20, 15, 3, 4, 4, 1}
... | [
{
"code": null,
"e": 54,
"s": 26,
"text": "\n01 Jul, 2021"
},
{
"code": null,
"e": 311,
"s": 54,
"text": "Given a stream of integers, lookup the rank of a given integer x. Rank of an integer in-stream is “Total number of elements less than or equal to x (not including x)”.If an e... |
Binarytree Module in Python - GeeksforGeeks | 25 Aug, 2021
A binary tree is a data structure in which every node or vertex has atmost two children. In Python, a binary tree can be represented in different ways with different data structures(dictionary, list) and class representation for a node. However, binarytree library helps to directly implement a binary tree.... | [
{
"code": null,
"e": 23912,
"s": 23884,
"text": "\n25 Aug, 2021"
},
{
"code": null,
"e": 24405,
"s": 23912,
"text": "A binary tree is a data structure in which every node or vertex has atmost two children. In Python, a binary tree can be represented in different ways with differe... |
How to get the current open file line in Python? | Python doesn't support this directly. You could write a wrapper class for it. For example,
class FileLineWrapper(object):
def __init__(self, file):
self.f = file
self.curr_line = 0
def close(self):
return self.f.close()
def readline(self):
self.curr_line += 1
return s... | [
{
"code": null,
"e": 1153,
"s": 1062,
"text": "Python doesn't support this directly. You could write a wrapper class for it. For example,"
},
{
"code": null,
"e": 1558,
"s": 1153,
"text": "class FileLineWrapper(object):\n def __init__(self, file):\n self.f = file\n ... |
Kali Linux - Stressing Tools | Stressing tools are used to create DoS attacks or to create the stress test for different applications so as take appropriate measures for the future.
All the Stress testing tools are found in Applications → 02-Vulnerability Analysis → Stress testing.
All Stress testing test will be done on metsploitable machine which ... | [
{
"code": null,
"e": 2180,
"s": 2029,
"text": "Stressing tools are used to create DoS attacks or to create the stress test for different applications so as take appropriate measures for the future."
},
{
"code": null,
"e": 2281,
"s": 2180,
"text": "All the Stress testing tools ar... |
Python program to fetch the indices of true values in a Boolean list | 07 Jun, 2019
Given a list of only boolean values, write a Python program to fetch all the indices with True values from given list.
Let’s see certain ways to do this task.
Method #1: Using itertools [Pythonic way]
itertools.compress() function checks for all the elements in list and returns the list of indices with Tru... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n07 Jun, 2019"
},
{
"code": null,
"e": 147,
"s": 28,
"text": "Given a list of only boolean values, write a Python program to fetch all the indices with True values from given list."
},
{
"code": null,
"e": 187,
"s": 147,
... |
Number of substrings of a string | 31 May, 2022
Find total number of non-empty substrings of a string with N characters.
Input : str = “abc” Output : 6 Every substring of the given string : “a”, “b”, “c”, “ab”, “bc”, “abc”
Input : str = “abcd” Output : 10 Every substring of the given string : “a”, “b”, “c”, “d”, “ab”, “bc”, “cd”, “abc”, “bcd” and “abcd... | [
{
"code": null,
"e": 52,
"s": 24,
"text": "\n31 May, 2022"
},
{
"code": null,
"e": 126,
"s": 52,
"text": "Find total number of non-empty substrings of a string with N characters. "
},
{
"code": null,
"e": 228,
"s": 126,
"text": "Input : str = “abc” Output : 6 ... |
Python Pillow - Using Image Module | To display the image, pillow library is using an image class within it. The image module inside pillow package contains some important inbuilt functions like, load images or create new images, etc.
To load the image, we simply import the image module from the pillow and call the Image.open(), passing the image filename... | [
{
"code": null,
"e": 2532,
"s": 2334,
"text": "To display the image, pillow library is using an image class within it. The image module inside pillow package contains some important inbuilt functions like, load images or create new images, etc."
},
{
"code": null,
"e": 2656,
"s": 253... |
R - XML Files | XML is a file format which shares both the file format and the data on the World Wide Web, intranets, and elsewhere using standard ASCII text. It stands for Extensible Markup Language (XML). Similar to HTML it contains markup tags. But unlike HTML where the markup tag describes structure of the page, in xml the markup ... | [
{
"code": null,
"e": 2918,
"s": 2536,
"text": "XML is a file format which shares both the file format and the data on the World Wide Web, intranets, and elsewhere using standard ASCII text. It stands for Extensible Markup Language (XML). Similar to HTML it contains markup tags. But unlike HTML where... |
How can we validate decimal numbers in JavaScript? | Following is the code to validate decimal numbers 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, Geneva, Verdana, sans-se... | [
{
"code": null,
"e": 1253,
"s": 1187,
"text": "Following is the code to validate decimal numbers in JavaScript −"
},
{
"code": null,
"e": 1264,
"s": 1253,
"text": " Live Demo"
},
{
"code": null,
"e": 2303,
"s": 1264,
"text": "<!DOCTYPE html>\n<html lang=\"en\"... |
Include v/s Extend in Ruby | 18 Mar, 2021
Include is used to importing module code. Ruby will throw an error when we try to access the methods of import module with the class directly because it gets imported as a subclass for the superclass. So, the only way is to access it through the instance of the class.
Extend is also used to importing modul... | [
{
"code": null,
"e": 53,
"s": 25,
"text": "\n18 Mar, 2021"
},
{
"code": null,
"e": 322,
"s": 53,
"text": "Include is used to importing module code. Ruby will throw an error when we try to access the methods of import module with the class directly because it gets imported as a su... |
Rounding Floating Point Number To two Decimal Places in C and C++ | 07 Aug, 2021
How to round off a floating point value to two places. For example, 5.567 should become 5.57 and 5.534 should become 5.53
First Method:- Using Float precision
C++
C
#include<bits/stdc++.h>using namespace std; int main(){ float var = 37.66666; // Directly print the number with .2f precision cout ... | [
{
"code": null,
"e": 54,
"s": 26,
"text": "\n07 Aug, 2021"
},
{
"code": null,
"e": 176,
"s": 54,
"text": "How to round off a floating point value to two places. For example, 5.567 should become 5.57 and 5.534 should become 5.53"
},
{
"code": null,
"e": 214,
"s": 1... |
Python | Pandas Series.isnull() | 12 Feb, 2019
Pandas series is a One-dimensional ndarray with axis labels. The labels need not be unique but must be a hashable type. The object supports both integer and label-based indexing and provides a host of methods for performing operations involving the index.
Pandas Series.isnull() function detect missing valu... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n12 Feb, 2019"
},
{
"code": null,
"e": 284,
"s": 28,
"text": "Pandas series is a One-dimensional ndarray with axis labels. The labels need not be unique but must be a hashable type. The object supports both integer and label-based indexi... |
Generic Set In Java | 24 Oct, 2020
The Set interface is present in java.util package. It is basically a collection of objects with no duplicate objects that means there can be no two objects in a Set e1 and e2 such that e1.equals(e2) and at most one null element. It is an interface that models the mathematical set. This interface inherits t... | [
{
"code": null,
"e": 53,
"s": 25,
"text": "\n24 Oct, 2020"
},
{
"code": null,
"e": 570,
"s": 53,
"text": "The Set interface is present in java.util package. It is basically a collection of objects with no duplicate objects that means there can be no two objects in a Set e1 and e2... |
pandas.bdate_range() function in Python | 14 Aug, 2020
This method is used to return a fixed frequency DatetimeIndex, with the business day as the default frequency.
Syntax : pandas.bdate_range(start=None, end=None, periods=None, freq=’B’, tz=None, normalize=True, name=None, weekmask=None, holidays=None, closed=None, **kwargs,)
Parameters :
start : string or d... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n14 Aug, 2020"
},
{
"code": null,
"e": 139,
"s": 28,
"text": "This method is used to return a fixed frequency DatetimeIndex, with the business day as the default frequency."
},
{
"code": null,
"e": 303,
"s": 139,
"tex... |
Design and Analysis Shortest Paths | Dijkstra’s algorithm solves the single-source shortest-paths problem on a directed weighted graph G = (V, E), where all the edges are non-negative (i.e., w(u, v) ≥ 0 for each edge (u, v) Є E).
In the following algorithm, we will use one function Extract-Min(), which extracts the node with the smallest key.
Algorithm: D... | [
{
"code": null,
"e": 2926,
"s": 2733,
"text": "Dijkstra’s algorithm solves the single-source shortest-paths problem on a directed weighted graph G = (V, E), where all the edges are non-negative (i.e., w(u, v) ≥ 0 for each edge (u, v) Є E)."
},
{
"code": null,
"e": 3041,
"s": 2926,
... |
Program to check whether a binary tree is BST or not in Python | Suppose we have binary tree; we have to check whether it is a binary search tree or not. As we know a BST has following properties −
all nodes on its left subtree is smaller than current node value
all nodes on its right subtree is larger than current node value
these properties hold recursively for all nodes
So, if th... | [
{
"code": null,
"e": 1320,
"s": 1187,
"text": "Suppose we have binary tree; we have to check whether it is a binary search tree or not. As we know a BST has following properties −"
},
{
"code": null,
"e": 1385,
"s": 1320,
"text": "all nodes on its left subtree is smaller than cur... |
How to check if email address is already in use or not using express-validator in Node.js ? | 08 Apr, 2022
The registration or Sign Up in any website always requires a username. Most of the time we use ’email’ to register on a website. The registration email is always unique and must refer to only one user otherwise conflict between the users can happen. To solve this conflict every website must have the functi... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n08 Apr, 2022"
},
{
"code": null,
"e": 696,
"s": 28,
"text": "The registration or Sign Up in any website always requires a username. Most of the time we use ’email’ to register on a website. The registration email is always unique and mu... |
VLAN ACL (VACL) | 19 Oct, 2021
Prerequisite – Virtual LAN (VLAN), Access-lists (ACL) VLAN (Virtual LAN) is a concept in which we divide the broadcast domain into smaller broadcast domains logically at layer 2. If we create different VLANs then by default, a host from one VLAN can communicate with all the hosts residing in the same VLAN.... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n19 Oct, 2021"
},
{
"code": null,
"e": 565,
"s": 28,
"text": "Prerequisite – Virtual LAN (VLAN), Access-lists (ACL) VLAN (Virtual LAN) is a concept in which we divide the broadcast domain into smaller broadcast domains logically at layer... |
How to create Neon Light Button using HTML and CSS ? | 16 Aug, 2021
The neon light button animation effect can be easily generated by using HTML and CSS. By using HTML we will design the basic structure of the button and then by using the properties of CSS, we can create the neon light animation effect. HTML code: In this section, we will design a simple button structure u... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n16 Aug, 2021"
},
{
"code": null,
"e": 353,
"s": 28,
"text": "The neon light button animation effect can be easily generated by using HTML and CSS. By using HTML we will design the basic structure of the button and then by using the prop... |
PyQt5 – Changing size of Indicator in Check Box | 22 Apr, 2020
In this article we will see how to change the size of indicator. Indicator is the part of check box although if we change the size of check box with the help of resize method or setGeometry method, but it will change the size of check box but not the indicator.
In order to change the size of indicator we h... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n22 Apr, 2020"
},
{
"code": null,
"e": 290,
"s": 28,
"text": "In this article we will see how to change the size of indicator. Indicator is the part of check box although if we change the size of check box with the help of resize method ... |
Stream skip() method in Java with examples | 06 Dec, 2018
Prerequisite : Streams in javaThe skip(long N) is a method of java.util.stream.Stream object. This method takes one long (N) as an argument and returns a stream after removing first N elements. skip() can be quite expensive on ordered parallel pipelines, if the value of N is large, because skip(N) is const... | [
{
"code": null,
"e": 54,
"s": 26,
"text": "\n06 Dec, 2018"
},
{
"code": null,
"e": 532,
"s": 54,
"text": "Prerequisite : Streams in javaThe skip(long N) is a method of java.util.stream.Stream object. This method takes one long (N) as an argument and returns a stream after removin... |
Object Level Lock vs Class Level Lock in Java | 19 Apr, 2022
Synchronized is the modifier applicable only for methods and blocks but not for classes and variables. If multiple threads are trying to operate simultaneously on the same java object then there may be a chance of data inconsistency problem to overcome this problem we should go for a ‘synchronized‘ keyword... | [
{
"code": null,
"e": 53,
"s": 25,
"text": "\n19 Apr, 2022"
},
{
"code": null,
"e": 770,
"s": 53,
"text": "Synchronized is the modifier applicable only for methods and blocks but not for classes and variables. If multiple threads are trying to operate simultaneously on the same ja... |
Python – Variations of Principal Component Analysis | 26 Jun, 2021
Principal Component Analysis (PCA) is an unsupervised dimensionality reduction and visualisation technique. It is often referred to as a linear technique because the mapping of new features is given by the multiplication of feature by the matrix of PCA eigenvectors. It works by simply identifying the hyper... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n26 Jun, 2021"
},
{
"code": null,
"e": 726,
"s": 28,
"text": "Principal Component Analysis (PCA) is an unsupervised dimensionality reduction and visualisation technique. It is often referred to as a linear technique because the mapping o... |
How to Install R Studio on Windows and Linux? | 13 Oct, 2021
R programming language is a language and free software environment, available under GNU license, supported by R Foundation for Statistical Computing. The language is most widely known for its powerful statistical and data interpretation capabilities.
To use R language, you need the R environment to be ins... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n13 Oct, 2021"
},
{
"code": null,
"e": 280,
"s": 28,
"text": "R programming language is a language and free software environment, available under GNU license, supported by R Foundation for Statistical Computing. The language is most wide... |
Extended Access-List | 15 Mar, 2022
Prerequisite – Access-lists (ACL), Standard Access-list Access-list (ACL) is a set of rules defined for controlling network traffic and reducing network attacks. ACLs are used to filter traffic based on the set of rules defined for the incoming or outgoing of the network.
Extended Access-list – It is one ... | [
{
"code": null,
"e": 52,
"s": 24,
"text": "\n15 Mar, 2022"
},
{
"code": null,
"e": 326,
"s": 52,
"text": "Prerequisite – Access-lists (ACL), Standard Access-list Access-list (ACL) is a set of rules defined for controlling network traffic and reducing network attacks. ACLs are use... |
TypeScript | Array indexOf() Method | 18 Jun, 2020
The Array.indexOf() is an inbuilt TypeScript function which is used to find the index of the first occurrence of the search element provided as the argument to the function. Syntax:
array.indexOf(searchElement[, fromIndex])
Parameter: This method accepts two parameter as mentioned above and described belo... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n18 Jun, 2020"
},
{
"code": null,
"e": 211,
"s": 28,
"text": "The Array.indexOf() is an inbuilt TypeScript function which is used to find the index of the first occurrence of the search element provided as the argument to the function. ... |
How to Get the Shape of a Tensor as a List of int in Pytorch? | 04 Jul, 2021
To get the shape of a tensor as a list in PyTorch, we can use two approaches. One using the size() method and another by using the shape attribute of a tensor in PyTorch. In this short article, we are going to see how to use both of the approaches.
The size() method returns the size of the self tensor. The... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n04 Jul, 2021"
},
{
"code": null,
"e": 277,
"s": 28,
"text": "To get the shape of a tensor as a list in PyTorch, we can use two approaches. One using the size() method and another by using the shape attribute of a tensor in PyTorch. In t... |
Python | Scramble words from a text file | 11 Oct, 2021
Given some data in a text file, the task is to scramble the text and output in a separate text file. So, we need to write a Python program that reads a text file, scrambles the words in the file and writes the output to a new text file.
Rules to be followed:
Words less than or equal to 3 characters need n... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n11 Oct, 2021"
},
{
"code": null,
"e": 265,
"s": 28,
"text": "Given some data in a text file, the task is to scramble the text and output in a separate text file. So, we need to write a Python program that reads a text file, scrambles th... |
Microsoft Archives - GeeksforGeeks | Merge Sort
Largest Sum Contiguous Subarray
Reverse a linked list
Binary Search Tree | Set 1 (Search and Insertion)
Level Order Binary Tree Traversal
Stack Data Structure (Introduction and Program)
Topological Sorting
Given an array A[] and a number x, check for pair in A[] with sum as x (aka Two Sum)
Detect Cycle in a ... | [
{
"code": null,
"e": 24141,
"s": 24130,
"text": "Merge Sort"
},
{
"code": null,
"e": 24173,
"s": 24141,
"text": "Largest Sum Contiguous Subarray"
},
{
"code": null,
"e": 24195,
"s": 24173,
"text": "Reverse a linked list"
},
{
"code": null,
"e": 242... |
Lodash _.toPairs() Method | 09 Sep, 2020
The _.toPairs() method is used to create an array of own enumerable string key-value pairs for an object which can be consumed by the _.fromPairs() function. If the object is a map or set, its entries are returned.
Syntax:
_.toPairs(object)
Parameters: This method accepts a single parameter as mentioned a... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n09 Sep, 2020"
},
{
"code": null,
"e": 243,
"s": 28,
"text": "The _.toPairs() method is used to create an array of own enumerable string key-value pairs for an object which can be consumed by the _.fromPairs() function. If the object is ... |
IBM Placement Paper | Logical Reasoning Set – 1 | 24 May, 2019
This is an IBM model placement paper on Logical Reasoning for placement preparation. This placement paper will cover logical reasoning questions that are asked in IBM recruitment drives and also strictly follows the pattern of questions asked in IBM interviews. It is recommended to solve each one of the fo... | [
{
"code": null,
"e": 53,
"s": 25,
"text": "\n24 May, 2019"
},
{
"code": null,
"e": 434,
"s": 53,
"text": "This is an IBM model placement paper on Logical Reasoning for placement preparation. This placement paper will cover logical reasoning questions that are asked in IBM recruit... |
PLSQL | TRUNC Function | 01 Nov, 2019
The TRUNC function is an inbuilt function in PLSQL which is used to return a number truncated to a particular number of decimal places.
Syntax:
TRUNC( number, decimal_places )
Parameters Used:This function accepts two parameters which are illustrated below:-
number – This is the input number which is going... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n01 Nov, 2019"
},
{
"code": null,
"e": 164,
"s": 28,
"text": "The TRUNC function is an inbuilt function in PLSQL which is used to return a number truncated to a particular number of decimal places."
},
{
"code": null,
"e": 17... |
Output of python program | Set 14 (Dictionary) | 23 Jun, 2021
Prerequisite: Dictionary Note: Output of all these programs is tested on Python31) What is the output of the following program?
PYTHON3
D = dict()for x in enumerate(range(2)): D[x[0]] = x[1] D[x[1]+7] = x[0]print(D)
a) KeyError b) {0: 1, 7: 0, 1: 1, 8: 0} c) {0: 0, 7: 0, 1: 1, 8: 1} d) {1: 1, 7: 2,... | [
{
"code": null,
"e": 54,
"s": 26,
"text": "\n23 Jun, 2021"
},
{
"code": null,
"e": 184,
"s": 54,
"text": "Prerequisite: Dictionary Note: Output of all these programs is tested on Python31) What is the output of the following program? "
},
{
"code": null,
"e": 192,
... |
Contiguous unique substrings with the given length L | 28 Dec, 2021
Given a string str and an integer L. The task is to print all the unique substring of length L from string str.
Examples:
Input: str = “abca”, L=3Output: “abc”, “bca”
Input: str = “aaaa”, L=3Output: “aaa”
Approach:Firstly generate all the substring of length L and then by using set we can insert unique sub... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n28 Dec, 2021"
},
{
"code": null,
"e": 140,
"s": 28,
"text": "Given a string str and an integer L. The task is to print all the unique substring of length L from string str."
},
{
"code": null,
"e": 150,
"s": 140,
"te... |
A Quickstart Guide to TensorBoard | by Rohan Jagtap | Towards Data Science | Everyone agrees that “visuals are better than text”. Visualizations offer feasibility and interactivity in any kind of interpretation. Same goes for ML modeling. One may wish to monitor the training losses or weights and biases to improve the model performance. This can be visualized using TensorBoard.
TensorBoard is T... | [
{
"code": null,
"e": 476,
"s": 172,
"text": "Everyone agrees that “visuals are better than text”. Visualizations offer feasibility and interactivity in any kind of interpretation. Same goes for ML modeling. One may wish to monitor the training losses or weights and biases to improve the model perfor... |
Yii - Fields | By overriding fields() and extraFields() methods, you can define what data can be put into a response. The difference between these two methods is that the former defines the default set of fields, which should be included in the response while the latter defines additional fields, which may be included in the response... | [
{
"code": null,
"e": 3219,
"s": 2833,
"text": "By overriding fields() and extraFields() methods, you can define what data can be put into a response. The difference between these two methods is that the former defines the default set of fields, which should be included in the response while the latt... |
Query Metabase data in Python. Metabase rest API and Python API | by Sophia Yang | Towards Data Science | Metabase is an open-source BI tool, where you can store data, connect to outside data sources, query, and visualizing data. This article talks about when we have data stored in Metabase, how do we query the data and get results in Python. The first part of this article talks about how to use the Metabase rest API to qu... | [
{
"code": null,
"e": 561,
"s": 172,
"text": "Metabase is an open-source BI tool, where you can store data, connect to outside data sources, query, and visualizing data. This article talks about when we have data stored in Metabase, how do we query the data and get results in Python. The first part o... |
How to convert JSON to CSV file using PowerShell? | To convert the JSON to the CSV format we need to first use the ConvertFrom-JSON command. For example, we have already JSON file present with us at the C:\temp\VMinfo.JSON location. We will first import this file and then convert it to CSV as shown below.
Get-Content C:\Temp\VMInfo.json | ConvertFrom-Json | Export-Csv C... | [
{
"code": null,
"e": 1317,
"s": 1062,
"text": "To convert the JSON to the CSV format we need to first use the ConvertFrom-JSON command. For example, we have already JSON file present with us at the C:\\temp\\VMinfo.JSON location. We will first import this file and then convert it to CSV as shown bel... |
Software Testing and Machine Learning | by Scott Lindeman | Towards Data Science | Let’s face it, machine learning (ML) is becoming a standard part of many software systems. A trained model in your system may be surfacing predictions directly to users to help them make a human decision, or it may be making automatic decisions within the software system itself. Whether the ML in a system is developed ... | [
{
"code": null,
"e": 875,
"s": 172,
"text": "Let’s face it, machine learning (ML) is becoming a standard part of many software systems. A trained model in your system may be surfacing predictions directly to users to help them make a human decision, or it may be making automatic decisions within the... |
Tryit Editor v3.7 | Table Colspan & Rowspan
Tryit: HTML table - rowspan | [
{
"code": null,
"e": 46,
"s": 22,
"text": "Table Colspan & Rowspan"
}
] |
How to validate expiry date on a MySQL query? | You can use NOW() for this. Following is the syntax −
select * from yourTableName
where yourColumnName> now();
Let us first create a table −
mysql> create table DemoTable
(
Id int NOT NULL AUTO_INCREMENT PRIMARY KEY,
expiryDateOfMedicine datetime
);
Query OK, 0 rows affected (0.55 sec)
Insert records in the... | [
{
"code": null,
"e": 1116,
"s": 1062,
"text": "You can use NOW() for this. Following is the syntax −"
},
{
"code": null,
"e": 1173,
"s": 1116,
"text": "select * from yourTableName\nwhere yourColumnName> now();"
},
{
"code": null,
"e": 1203,
"s": 1173,
"text": ... |
How to switch different browser tabs using Python Selenium? | We can switch different browser tabs using Selenium webdriver in Python using the method switch_to.window. By default, the webdriver has access to the parent window.
Once another browser tab is opened, the switch_to.window helps to switch the webdriver focus to the tab. The window handle of the browser window where we ... | [
{
"code": null,
"e": 1228,
"s": 1062,
"text": "We can switch different browser tabs using Selenium webdriver in Python using the method switch_to.window. By default, the webdriver has access to the parent window."
},
{
"code": null,
"e": 1437,
"s": 1228,
"text": "Once another bro... |
React-Bootstrap Tabs Component - GeeksforGeeks | 24 Sep, 2021
React-Bootstrap is a front-end framework that was designed keeping react in mind. Tabs Component provides a way to make form dynamic tabbed interfaces. With the help of tabs, the user can switch between components present in given different tabs. We can use the following approach in ReactJS to use the reac... | [
{
"code": null,
"e": 24274,
"s": 24246,
"text": "\n24 Sep, 2021"
},
{
"code": null,
"e": 24609,
"s": 24274,
"text": "React-Bootstrap is a front-end framework that was designed keeping react in mind. Tabs Component provides a way to make form dynamic tabbed interfaces. With the he... |
Logical AND and OR in Arduino | The logical AND is denoted by the && operator, while the logical OR is denoted by the || operator.
Expression1 && Expression2
OR
Expression1 || Expression2
Where expression1 and expression2 evaluate to Boolean values (true or false). The output of these statements is determined by the truth tables of logical AND and OR... | [
{
"code": null,
"e": 1161,
"s": 1062,
"text": "The logical AND is denoted by the && operator, while the logical OR is denoted by the || operator."
},
{
"code": null,
"e": 1188,
"s": 1161,
"text": "Expression1 && Expression2"
},
{
"code": null,
"e": 1191,
"s": 1188... |
C Program to print Floyd's triangle - GeeksforGeeks | 24 Feb, 2022
Floyd’s triangle is a triangle with first natural numbers.
1
2 3
4 5 6
7 8 9 10
11 12 13 14 15
Following program prints Floyd’s triangle with n lines.
C++
C
Java
Python3
C#
PHP
Javascript
#include <bits/stdc++.h>using namespace std; void printFloydTriangle(int ... | [
{
"code": null,
"e": 25840,
"s": 25812,
"text": "\n24 Feb, 2022"
},
{
"code": null,
"e": 25901,
"s": 25840,
"text": "Floyd’s triangle is a triangle with first natural numbers. "
},
{
"code": null,
"e": 25977,
"s": 25901,
"text": "1\n2 3\n4 5 6\n7 ... |
Find all prime factors of a number - JavaScript | We are required to write a JavaScript function that takes in a number and returns an array of all the prime numbers that exactly divide the input number.
For example, if the input number is 18.
Then the output should be −
const output = [2, 3];
Let’s write the code for this function −
const num = 18;
const isPrime = (n... | [
{
"code": null,
"e": 1216,
"s": 1062,
"text": "We are required to write a JavaScript function that takes in a number and returns an array of all the prime numbers that exactly divide the input number."
},
{
"code": null,
"e": 1256,
"s": 1216,
"text": "For example, if the input nu... |
htpasswd - Unix, Linux Command | htpasswd [ -c ] [ -m ] [ -D ] passwdfile username
htpasswd -b [ -c ] [ -m | -d | -p | -s ] [ -D ] passwdfile username password
htpasswd -n [ -m | -d | -s | -p ] username
htpasswd -nb [ -m | -d | -s | -p ] username password
htpasswd is used to create and update the flat-files used to store usernames ... | [
{
"code": null,
"e": 10635,
"s": 10583,
"text": "\nhtpasswd [ -c ] [ -m ] [ -D ] passwdfile username\n"
},
{
"code": null,
"e": 10716,
"s": 10637,
"text": "\nhtpasswd -b [ -c ] [ -m | -d | -p | -s ] [ -D ] passwdfile username password\n"
},
{
"code": null,
"e": 10763,... |
How to change the ID of element using JavaScript ? - GeeksforGeeks | 23 Apr, 2020
Given an HTML document and the task is to change the ID of the element using JavaScript. There are two approaches that are discussed below:
Approach 1: We can use the id property to change the ID using JavaScript.
Example:<!DOCTYPE HTML><html> <head> <title> Change the ID of the element u... | [
{
"code": null,
"e": 25376,
"s": 25348,
"text": "\n23 Apr, 2020"
},
{
"code": null,
"e": 25516,
"s": 25376,
"text": "Given an HTML document and the task is to change the ID of the element using JavaScript. There are two approaches that are discussed below:"
},
{
"code": n... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.