title stringlengths 3 221 | text stringlengths 17 477k | parsed listlengths 0 3.17k |
|---|---|---|
SQL ALTER TABLE Statement | The ALTER TABLE statement is used to add, delete, or modify columns in an existing table.
The ALTER TABLE statement is also used to add and drop various constraints on
an existing table.
To add a column in a table, use the following syntax:
The following SQL adds an "Email" column to the "Customers" table:
To delete a... | [
{
"code": null,
"e": 90,
"s": 0,
"text": "The ALTER TABLE statement is used to add, delete, or modify columns in an existing table."
},
{
"code": null,
"e": 188,
"s": 90,
"text": "The ALTER TABLE statement is also used to add and drop various constraints on \nan existing table."
... |
Sorting a Dictionary in Python. How to sort a dictionary in python | by Luay Matalka | Towards Data Science | We can sort lists, tuples, strings, and other iterable objects in python since they are all ordered objects. Well, as of python 3.7, dictionaries remember the order of items inserted as well. Thus we are also able to sort dictionaries using python’s built-in sorted() function. Just like with other iterables, we can sor... | [
{
"code": null,
"e": 591,
"s": 172,
"text": "We can sort lists, tuples, strings, and other iterable objects in python since they are all ordered objects. Well, as of python 3.7, dictionaries remember the order of items inserted as well. Thus we are also able to sort dictionaries using python’s built... |
Solidity - Mapping | Mapping is a reference type as arrays and structs. Following is the syntax to declare a mapping type.
mapping(_KeyType => _ValueType)
Where
_KeyType − can be any built-in types plus bytes and string. No reference type or complex objects are allowed.
_KeyType − can be any built-in types plus bytes and string. No refere... | [
{
"code": null,
"e": 2657,
"s": 2555,
"text": "Mapping is a reference type as arrays and structs. Following is the syntax to declare a mapping type."
},
{
"code": null,
"e": 2690,
"s": 2657,
"text": "mapping(_KeyType => _ValueType)\n"
},
{
"code": null,
"e": 2696,
... |
Fraction - GeeksforGeeks | 14 May, 2021
A fraction is a ratio of two values. Fractions have the form a/b where a is called the numerator, b is called the denominator and b cannot equal 0 (since division by 0 is undefined). The denominator gives how many equal parts are there. The numerator represents how many of these are taken. For example, one... | [
{
"code": null,
"e": 24155,
"s": 24127,
"text": "\n14 May, 2021"
},
{
"code": null,
"e": 24517,
"s": 24155,
"text": "A fraction is a ratio of two values. Fractions have the form a/b where a is called the numerator, b is called the denominator and b cannot equal 0 (since division ... |
Change SQLite Connection Timeout using Python - GeeksforGeeks | 12 Jan, 2022
In this article, we will discuss how to change the SQLite connection timeout when connecting from Python.
A connection timeout is an error that occurs when it takes too long for a server to respond to a user’s request.
Connection timeouts usually occur when there are multiple active connections to a databa... | [
{
"code": null,
"e": 24292,
"s": 24264,
"text": "\n12 Jan, 2022"
},
{
"code": null,
"e": 24398,
"s": 24292,
"text": "In this article, we will discuss how to change the SQLite connection timeout when connecting from Python."
},
{
"code": null,
"e": 24511,
"s": 2439... |
F# - Sequences | Sequences, like lists also represent an ordered collection of values. However, the elements in a sequence or sequence expression are computed when required. They are not computed at once, and for this reason they are used to represent infinite data structures.
Sequences are defined using the following syntax −
seq { ex... | [
{
"code": null,
"e": 2422,
"s": 2161,
"text": "Sequences, like lists also represent an ordered collection of values. However, the elements in a sequence or sequence expression are computed when required. They are not computed at once, and for this reason they are used to represent infinite data stru... |
How to add HTML elements dynamically using JavaScript ? | 22 Nov, 2021
In this article, we learn how to add HTML elements dynamically using JavaScript. A basic understanding of HTML, CSS, and javascript is required. Here we are going to use a button and by clicking this button, we can add an HTML element dynamically in this example.
Approach: Create an HTML file with any name... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n22 Nov, 2021"
},
{
"code": null,
"e": 292,
"s": 28,
"text": "In this article, we learn how to add HTML elements dynamically using JavaScript. A basic understanding of HTML, CSS, and javascript is required. Here we are going to use a but... |
Decision Tree Classifiers in R Programming | 23 Dec, 2021
Classification is the task in which objects of several categories are categorized into their respective classes using the properties of classes. A classification model is typically used to,
Predict the class label for a new unlabeled data object
Provide a descriptive model explaining what features characte... | [
{
"code": null,
"e": 54,
"s": 26,
"text": "\n23 Dec, 2021"
},
{
"code": null,
"e": 244,
"s": 54,
"text": "Classification is the task in which objects of several categories are categorized into their respective classes using the properties of classes. A classification model is typ... |
How to iterate a JSON Array in Android using Kotlin? | This example demonstrates how to iterate a JSON Array in Android using 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"?>
<Relativ... | [
{
"code": null,
"e": 1266,
"s": 1187,
"text": "This example demonstrates how to iterate a JSON Array in Android using Kotlin."
},
{
"code": null,
"e": 1395,
"s": 1266,
"text": "Step 1 − Create a new project in Android Studio, go to File ⇉ New Project and fill all required details... |
std::cbrt() in C++ | 24 Jan, 2022
The std::cbrt() is an inbuilt function in C++ STL which is used to calculate the cube root of number. It accepts a number as argument and returns the cube root of that number.Syntax:
// Returns cube root num (num can be
// of type int, double, long double or
// long long type.
// The return type is same ... | [
{
"code": null,
"e": 53,
"s": 25,
"text": "\n24 Jan, 2022"
},
{
"code": null,
"e": 238,
"s": 53,
"text": "The std::cbrt() is an inbuilt function in C++ STL which is used to calculate the cube root of number. It accepts a number as argument and returns the cube root of that number... |
ReactJS | Router | 18 Feb, 2022
React Router is a standard library for routing in React. It enables the navigation among views of various components in a React Application, allows changing the browser URL, and keeps the UI in sync with the URL.Let us create a simple application to React to understand how the React Router works. The appli... | [
{
"code": null,
"e": 54,
"s": 26,
"text": "\n18 Feb, 2022"
},
{
"code": null,
"e": 520,
"s": 54,
"text": "React Router is a standard library for routing in React. It enables the navigation among views of various components in a React Application, allows changing the browser URL, ... |
multimap equal_range() in C++ STL | 13 Nov, 2020
The multimap::equal_range() is a built-in function in C++ STL which returns an iterator of pairs. The pair refers to the bounds of a range that includes all the elements in the container which have a key equivalent to k. If there are no matches with key K, the range returned is of length 0 with both iterat... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n13 Nov, 2020"
},
{
"code": null,
"e": 478,
"s": 28,
"text": "The multimap::equal_range() is a built-in function in C++ STL which returns an iterator of pairs. The pair refers to the bounds of a range that includes all the elements in th... |
Averages of Levels in Binary Tree | 01 Jul, 2021
Given a non-empty binary tree, print the average value of the nodes on each level.
Examples:
Input :
4
/ \
2 9
/ \ \
3 5 7
Output : [4 5.5 5]
The average value of nodes on level 0 is 4,
on level 1 is 5.5, and on level 2 is 5.
Hence, print [4 5.5 5].
The idea is based on Level order t... | [
{
"code": null,
"e": 52,
"s": 24,
"text": "\n01 Jul, 2021"
},
{
"code": null,
"e": 135,
"s": 52,
"text": "Given a non-empty binary tree, print the average value of the nodes on each level."
},
{
"code": null,
"e": 146,
"s": 135,
"text": "Examples: "
},
{
... |
numpy.tile() in Python | 28 Mar, 2022
The numpy.tile() function constructs a new array by repeating array – ‘arr’, the number of times we want to repeat as per repetitions. The resulted array will have dimensions max(arr.ndim, repetitions) where, repetitions is the length of repetitions. If arr.ndim > repetitions, reps is promoted to arr.ndim ... | [
{
"code": null,
"e": 52,
"s": 24,
"text": "\n28 Mar, 2022"
},
{
"code": null,
"e": 476,
"s": 52,
"text": "The numpy.tile() function constructs a new array by repeating array – ‘arr’, the number of times we want to repeat as per repetitions. The resulted array will have dimensions... |
Switch Statement in Java | 25 Jun, 2022
The switch statement is a multi-way branch statement. In simple words, the Java switch statement executes one statement from multiple conditions. It is like an if-else-if ladder statement. It provides an easy way to dispatch execution to different parts of code based on the value of the expression. Basical... | [
{
"code": null,
"e": 52,
"s": 24,
"text": "\n25 Jun, 2022"
},
{
"code": null,
"e": 506,
"s": 52,
"text": "The switch statement is a multi-way branch statement. In simple words, the Java switch statement executes one statement from multiple conditions. It is like an if-else-if lad... |
Reverse an array in groups of given size | Set 3 (Single traversal) | 13 Aug, 2021
Given an array, reverse every sub-array formed by consecutive k elements.
Examples:
Input: arr = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10], k = 3. Output: [3, 2, 1, 6, 5, 4, 9, 8, 7, 10]Input: arr = [1, 2, 3, 4, 5, 6, 7], k = 5. Output: [5, 4, 3, 2, 1, 7, 6]
Approach:
We will use two pointers technique to solve th... | [
{
"code": null,
"e": 53,
"s": 25,
"text": "\n13 Aug, 2021"
},
{
"code": null,
"e": 127,
"s": 53,
"text": "Given an array, reverse every sub-array formed by consecutive k elements."
},
{
"code": null,
"e": 138,
"s": 127,
"text": "Examples: "
},
{
"code"... |
Haskell - Modules | If you have worked on Java, then you would know how all the classes are bound into a folder called package. Similarly, Haskell can be considered as a collection of modules.
Haskell is a functional language and everything is denoted as an expression, hence a Module can be called as a collection of similar or related typ... | [
{
"code": null,
"e": 2222,
"s": 2049,
"text": "If you have worked on Java, then you would know how all the classes are bound into a folder called package. Similarly, Haskell can be considered as a collection of modules."
},
{
"code": null,
"e": 2386,
"s": 2222,
"text": "Haskell i... |
Python modf() Method | Python number method modf() returns the fractional and integer parts of x in a two-item tuple. Both parts have the same sign as x. The integer part is returned as a float.
Following is the syntax for modf() method −
import math
math.modf( x )
Note − This function is not accessible directly, so we need to import math ... | [
{
"code": null,
"e": 2417,
"s": 2244,
"text": "Python number method modf() returns the fractional and integer parts of x in a two-item tuple. Both parts have the same sign as x. The integer part is returned as a float."
},
{
"code": null,
"e": 2461,
"s": 2417,
"text": "Following... |
C Program to calculate the Round Trip Time (RTT) | Given an Url address of any website; the task is to calculate the round trip time of a website.
Round Trip Time(RTT) is the total time or the length of a time which is taken to send a signal plus the time taken to receive the acknowledgement of that signal to be received. This time also consist of the propagation times... | [
{
"code": null,
"e": 1158,
"s": 1062,
"text": "Given an Url address of any website; the task is to calculate the round trip time of a website."
},
{
"code": null,
"e": 1415,
"s": 1158,
"text": "Round Trip Time(RTT) is the total time or the length of a time which is taken to send ... |
Ultimate Beginners Guide to Collecting Text for Natural Language Processing (NLP) with Python — Twitter, Reddit, Genius and More | by Eric Kleppen | Towards Data Science | I’ve been fascinated by Natural Language Processing (NLP) since I got into data science a little over a year ago. Thanks to advancements in transfer learning, there has been some explosive progress in the field, and NLP products like Alexa and Siri have become household names. Since my background is technical writing a... | [
{
"code": null,
"e": 838,
"s": 171,
"text": "I’ve been fascinated by Natural Language Processing (NLP) since I got into data science a little over a year ago. Thanks to advancements in transfer learning, there has been some explosive progress in the field, and NLP products like Alexa and Siri have b... |
PHP timestamp to HTML5 input type=datetime element | For HTML5 input time, in PHP:
echo date("Y-m-d\TH:i:s");
The output would be:
2018-28-03T19:12:49
HTML with Timestamp would be:
<input type="datetime" value="<?php echo date("Y-m-d\TH:i:s",$timestamp); ?>"/> | [
{
"code": null,
"e": 1092,
"s": 1062,
"text": "For HTML5 input time, in PHP:"
},
{
"code": null,
"e": 1119,
"s": 1092,
"text": "echo date(\"Y-m-d\\TH:i:s\");"
},
{
"code": null,
"e": 1140,
"s": 1119,
"text": "The output would be:"
},
{
"code": null,
... |
Using final with Inheritance in Java - GeeksforGeeks | 16 Mar, 2022
Prerequisite – Overriding in java, Inheritance final is a keyword in java used for restricting some functionalities. We can declare variables, methods, and classes with the final keyword.
Using final with inheritance
During inheritance, we must declare methods with the final keyword for which we are requ... | [
{
"code": null,
"e": 23017,
"s": 22989,
"text": "\n16 Mar, 2022"
},
{
"code": null,
"e": 23207,
"s": 23017,
"text": "Prerequisite – Overriding in java, Inheritance final is a keyword in java used for restricting some functionalities. We can declare variables, methods, and classes... |
How to Run Scrapy From a Script. Forget about scrapy’s framework and... | by Aaron S | Towards Data Science | Scrapy is a great framework to use for scraping projects. However, did you know there is a way to run Scrapy straight from a script?
Looking at the documentation, there are two ways to run Scrapy. Using the Scrapy API or the framework.
Why you would use scrapy from a scriptUnderstand the basic script every time you wan... | [
{
"code": null,
"e": 180,
"s": 47,
"text": "Scrapy is a great framework to use for scraping projects. However, did you know there is a way to run Scrapy straight from a script?"
},
{
"code": null,
"e": 283,
"s": 180,
"text": "Looking at the documentation, there are two ways to ru... |
\def - Tex Command | \def - Used for defining your own commands.
{ \def\myCommandName{ <replacement text> } }
\def command is used to define your own commands (control sequences, macros, definitions); must appear (within math delimiters) before it is used;
\def\myHearts{\color{purple}{\heartsuit}\kern-2.5pt\color{green}{\heartsuit}}
\myHe... | [
{
"code": null,
"e": 8030,
"s": 7986,
"text": "\\def - Used for defining your own commands."
},
{
"code": null,
"e": 8075,
"s": 8030,
"text": "{ \\def\\myCommandName{ <replacement text> } }"
},
{
"code": null,
"e": 8222,
"s": 8075,
"text": "\\def command is us... |
Logging in SAP using command line | sapshcut.exe command can be used to log in to SAP from command line as shown in below example:
Add the directory that contains the sapshcut.exe command to your system or user path. The sapshcut.exe command is installed as part of the SAP client into the following directory: C:\Program Files\SAP\FrontEnd\SAPguiTo add ad... | [
{
"code": null,
"e": 1157,
"s": 1062,
"text": "sapshcut.exe command can be used to log in to SAP from command line as shown in below example:"
},
{
"code": null,
"e": 1737,
"s": 1157,
"text": "Add the directory that contains the sapshcut.exe command to your system or user path. T... |
Find closest smaller value for every element in array in C++ | Here we will see how to find the closest value for every element in an array. If an element x has the next element that is larger than it, and also present in the array, then that will be the greater value of that element. If the element is not present, then return -1. Suppose the array elements are [10, 5, 11, 6, 20, ... | [
{
"code": null,
"e": 1499,
"s": 1062,
"text": "Here we will see how to find the closest value for every element in an array. If an element x has the next element that is larger than it, and also present in the array, then that will be the greater value of that element. If the element is not present,... |
C# | String Concat with examples | Set-3 - GeeksforGeeks | 01 Feb, 2019
String.Concat Method is used to concatenate one or more instances of String or the String representations of the values of one or more instances of Object. It always returns a concatenated string.This method can be overloaded by passing different types and number of parameters to it. There are total 11 met... | [
{
"code": null,
"e": 24302,
"s": 24274,
"text": "\n01 Feb, 2019"
},
{
"code": null,
"e": 24752,
"s": 24302,
"text": "String.Concat Method is used to concatenate one or more instances of String or the String representations of the values of one or more instances of Object. It alwa... |
Python List extend() Method - GeeksforGeeks | 05 Aug, 2021
The Python’s List extend() method iterates over an iterable like string, list, tuple, etc., and adds each element of the iterable to the end of List. The length of the list increases by the number of elements present in the iterable.
Syntax: list.extend(iterable)
Parameters:
iterable: Any iterable (list, s... | [
{
"code": null,
"e": 23901,
"s": 23873,
"text": "\n05 Aug, 2021"
},
{
"code": null,
"e": 24135,
"s": 23901,
"text": "The Python’s List extend() method iterates over an iterable like string, list, tuple, etc., and adds each element of the iterable to the end of List. The length of... |
Build a Text Generator Web App in under 50 Lines of Python | by Dev Sharma | Towards Data Science | We will be using OpenAI’s GPT-2 as the model and Panel as the web dashboard framework. This guide will be split into two parts. In the first part, we will load our model and write a predictions function. In the second, we will build the web application.
This tutorial assumes you already have Python 3.7+ installed and h... | [
{
"code": null,
"e": 426,
"s": 172,
"text": "We will be using OpenAI’s GPT-2 as the model and Panel as the web dashboard framework. This guide will be split into two parts. In the first part, we will load our model and write a predictions function. In the second, we will build the web application."
... |
Ruby on Rails - Controller | The Rails controller is the logical center of your application. It coordinates the interaction between the user, the views, and the model. The controller is also a home to a number of important ancillary services.
It is responsible for routing external requests to internal actions. It handles people-friendly URLs extre... | [
{
"code": null,
"e": 2317,
"s": 2103,
"text": "The Rails controller is the logical center of your application. It coordinates the interaction between the user, the views, and the model. The controller is also a home to a number of important ancillary services."
},
{
"code": null,
"e": 24... |
Difference between PUT and POST HTTP requests - GeeksforGeeks | 31 Aug, 2021
PUT and POST requests have lots of similarities certainly when making an HTTP request and both can be meddled with so that one performs functions of the other. This article revolves around the major differences between PUT and POST Requests.
PUT is a request method supported by HTTP used by the World Wide... | [
{
"code": null,
"e": 25855,
"s": 25827,
"text": "\n31 Aug, 2021"
},
{
"code": null,
"e": 26098,
"s": 25855,
"text": "PUT and POST requests have lots of similarities certainly when making an HTTP request and both can be meddled with so that one performs functions of the other. Thi... |
Python | Print Alphabets till N - GeeksforGeeks | 26 Nov, 2019
Sometimes, while working with Python, we can have a problem in which we need to print specific number of alphabets in order. This can have application in school level programming. Let’s discuss certain ways in which this problem can be solved.
Method #1 : Using loop + chr()This is brute force way to perfor... | [
{
"code": null,
"e": 25672,
"s": 25644,
"text": "\n26 Nov, 2019"
},
{
"code": null,
"e": 25916,
"s": 25672,
"text": "Sometimes, while working with Python, we can have a problem in which we need to print specific number of alphabets in order. This can have application in school le... |
AngularJS | ng-click Directive - GeeksforGeeks | 28 Mar, 2019
The ng-click Directive in AngluarJS is used to apply custom behavior when an element is clicked. It can be used to show/hide some element or it can popup alert when button is clicked.
Syntax:
<element ng-click="expression"> Contents... </element>
Example 1: This example uses ng-click Directive to display a... | [
{
"code": null,
"e": 29626,
"s": 29598,
"text": "\n28 Mar, 2019"
},
{
"code": null,
"e": 29810,
"s": 29626,
"text": "The ng-click Directive in AngluarJS is used to apply custom behavior when an element is clicked. It can be used to show/hide some element or it can popup alert whe... |
Check if a word exists in a grid or not - GeeksforGeeks | 20 Jan, 2022
Given a 2D grid of characters and a word, the task is to check if that word exists in the grid or not. A word can be matched in 4 directions at any point.The 4 directions are, Horizontally Left and Right, Vertically Up and Down. Examples:
Input: grid[][] = {"axmy",
"bgdf",
... | [
{
"code": null,
"e": 24606,
"s": 24578,
"text": "\n20 Jan, 2022"
},
{
"code": null,
"e": 24847,
"s": 24606,
"text": "Given a 2D grid of characters and a word, the task is to check if that word exists in the grid or not. A word can be matched in 4 directions at any point.The 4 dir... |
Binary Search (bisect) in Python - GeeksforGeeks | 04 Feb, 2022
Binary Search is a technique used to search element in a sorted list. In this article, we will looking at library functions to do Binary Search.Finding first occurrence of an element.
bisect.bisect_left(a, x, lo=0, hi=len(a)) : Returns leftmost insertion point of x in a sorted list. Last two parameters a... | [
{
"code": null,
"e": 26343,
"s": 26315,
"text": "\n04 Feb, 2022"
},
{
"code": null,
"e": 26529,
"s": 26343,
"text": "Binary Search is a technique used to search element in a sorted list. In this article, we will looking at library functions to do Binary Search.Finding first occur... |
How to Run PostgreSQL Using Docker | by Mahbub Zaman | Towards Data Science | PostgreSQL has been around for over 30 years. It was first developed in 1986 as part of the POSTGRES project at the University of California at Berkeley. Now it is the world’s most advanced open-source relational database. Running PostgreSQL on different machines can be challenging, but Docker makes it easier. From thi... | [
{
"code": null,
"e": 562,
"s": 172,
"text": "PostgreSQL has been around for over 30 years. It was first developed in 1986 as part of the POSTGRES project at the University of California at Berkeley. Now it is the world’s most advanced open-source relational database. Running PostgreSQL on different ... |
Sunburst Plot using Plotly in Python - GeeksforGeeks | 28 Jul, 2020
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.
Sunbu... | [
{
"code": null,
"e": 23677,
"s": 23649,
"text": "\n28 Jul, 2020"
},
{
"code": null,
"e": 23979,
"s": 23677,
"text": "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, sp... |
How to do a Custom Sort on Pandas DataFrame | by B. Chen | Towards Data Science | Pandas DataFrame has a built-in method sort_values() to sort values by the given variable(s). The method itself is fairly straightforward to use, however it doesn’t work for custom sorting, for example,
the t-shirt size: XS, S, M, L, and XL
the month: Jan, Feb, Mar, Apr , ....etc
the day of the week: Mon, Tue, Wed, Thu... | [
{
"code": null,
"e": 375,
"s": 172,
"text": "Pandas DataFrame has a built-in method sort_values() to sort values by the given variable(s). The method itself is fairly straightforward to use, however it doesn’t work for custom sorting, for example,"
},
{
"code": null,
"e": 413,
"s": 3... |
Responsive analog clock using HTML, CSS and Vanilla JavaScript - GeeksforGeeks | 04 Mar, 2021
In this article, we are going to create an Analog Clock. This is mainly based on HTML, CSS & Vanilla JavaScript.
Approach:
Create an HTML file in which we are going to add the main div, further on we are adding 4 div tags for an hour, minute, second hands & for the pin.Create a CSS file for styling our web... | [
{
"code": null,
"e": 24985,
"s": 24957,
"text": "\n04 Mar, 2021"
},
{
"code": null,
"e": 25098,
"s": 24985,
"text": "In this article, we are going to create an Analog Clock. This is mainly based on HTML, CSS & Vanilla JavaScript."
},
{
"code": null,
"e": 25108,
"s... |
How to rotate an image in imageview by an angle on Android using Kotlin? | This example demonstrates how to rotate an image in imageview by an angle on Android using 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" encodin... | [
{
"code": null,
"e": 1161,
"s": 1062,
"text": "This example demonstrates how to rotate an image in imageview by an angle on Android using Kotlin."
},
{
"code": null,
"e": 1290,
"s": 1161,
"text": "Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill ... |
Tryit Editor v3.7 | CSS Rounded Corners
Tryit: Creating rounded corners | [
{
"code": null,
"e": 29,
"s": 9,
"text": "CSS Rounded Corners"
}
] |
Best data type for storing currency values in a MySQL database? | For representation of money, we need to use Decimal (TotalDigitsinteger, DigitsAfterDecimalinteger) method.
Let’s say, we need to display the value 345.66. For that, count how many digits are available. In value 345.66, there are 5 digits in total and 2 digits after decimal point, which is 66.
We can represent the same... | [
{
"code": null,
"e": 1170,
"s": 1062,
"text": "For representation of money, we need to use Decimal (TotalDigitsinteger, DigitsAfterDecimalinteger) method."
},
{
"code": null,
"e": 1357,
"s": 1170,
"text": "Let’s say, we need to display the value 345.66. For that, count how many d... |
Top K Frequent Elements in Array - | | Practice | GeeksforGeeks | Given a non-empty array of integers, find the top k elements which have the highest frequency in the array. If two numbers have the same frequency then the larger number should be given preference.
Note: Print the elements according to the frequency count (from highest to lowest) and if the frequency is equal then lar... | [
{
"code": null,
"e": 437,
"s": 238,
"text": "Given a non-empty array of integers, find the top k elements which have the highest frequency in the array. If two numbers have the same frequency then the larger number should be given preference. "
},
{
"code": null,
"e": 595,
"s": 437,
... |
How to add a new column to a data frame using mutate in R? | The mutate function of dplyr package in R can help us to add a new column to a data frame and the benefit of using mutate is that we can decide the position of the new column during the addition. For example, if we have a data frame called df that contains three columns say x, y, a then we can add a new column say z af... | [
{
"code": null,
"e": 1475,
"s": 1062,
"text": "The mutate function of dplyr package in R can help us to add a new column to a data frame and the benefit of using mutate is that we can decide the position of the new column during the addition. For example, if we have a data frame called df that conta... |
Number of trailing zeroes in base B representation of N! - GeeksforGeeks | 13 Jul, 2021
Given two positive integers B and N. The task is to find the number of trailing zeroes in b-ary (base B) representation of N! (factorial of N)Examples:
Input: N = 5, B = 2
Output: 3
5! = 120 which is represented as 1111000 in base 2.
Input: N = 6, B = 9
Output: 1
A naive solution is to find the facto... | [
{
"code": null,
"e": 24737,
"s": 24709,
"text": "\n13 Jul, 2021"
},
{
"code": null,
"e": 24891,
"s": 24737,
"text": "Given two positive integers B and N. The task is to find the number of trailing zeroes in b-ary (base B) representation of N! (factorial of N)Examples: "
},
{... |
Professional 3-way Venn diagrams | Tailor labels and legend | Towards Data Science | As an avid python enthusiast, I recently came across the task of generating a 3-way Venn diagram. The quantity of time I spent on this seemingly simple task illuminated areas of sparsity in my working knowledge of matplotlib. May this tutorial aid others in efficiently customizing matplotlib embedded text to generate g... | [
{
"code": null,
"e": 594,
"s": 172,
"text": "As an avid python enthusiast, I recently came across the task of generating a 3-way Venn diagram. The quantity of time I spent on this seemingly simple task illuminated areas of sparsity in my working knowledge of matplotlib. May this tutorial aid others ... |
How to echo XML file in PHP | HTTP URLs can be used to behave like local files, with the help of PHP wrappers. The contents from a URL can be fetched through the file_get_contents() and it can be echoed. or read using the readfile function.
Below is a sample code to do the same −
$file = file_get_contents('http://example.com/');
echo $file;
An alte... | [
{
"code": null,
"e": 1273,
"s": 1062,
"text": "HTTP URLs can be used to behave like local files, with the help of PHP wrappers. The contents from a URL can be fetched through the file_get_contents() and it can be echoed. or read using the readfile function."
},
{
"code": null,
"e": 1313,... |
Where are static variables stored in C/C++? | Static variables are variables that remain in memory while the program is running i.e. their lifetime is the entire program run. This is different than automatic variables as they remain in memory only when their function is running and are destroyed when the function is over.
The static variables are stored in the dat... | [
{
"code": null,
"e": 1340,
"s": 1062,
"text": "Static variables are variables that remain in memory while the program is running i.e. their lifetime is the entire program run. This is different than automatic variables as they remain in memory only when their function is running and are destroyed wh... |
MySQL | CONNECTION_ID( ) Function - GeeksforGeeks | 25 Nov, 2019
The MySQL CONNECTION_ID() function is used for return the connection ID for a current connection in MySQL. The connection ID used to establish a connection to a database is unique for every connection among the connected clients. The CONNECTION_ID() function does not require any parameters or arguments.
Th... | [
{
"code": null,
"e": 24268,
"s": 24240,
"text": "\n25 Nov, 2019"
},
{
"code": null,
"e": 24573,
"s": 24268,
"text": "The MySQL CONNECTION_ID() function is used for return the connection ID for a current connection in MySQL. The connection ID used to establish a connection to a da... |
What is the difference between Math.ceil() and Math.round() methods in JavaScript? | Math.ceil() and Math.round() methods differ in a way that the former round off a number to its nearest integer in upward direction of rounding(towards the greater value) whereas the latter round off a number to its nearest integer in downward direction of rounding(towards lower value). Let's examine the two methods ind... | [
{
"code": null,
"e": 1393,
"s": 1062,
"text": "Math.ceil() and Math.round() methods differ in a way that the former round off a number to its nearest integer in upward direction of rounding(towards the greater value) whereas the latter round off a number to its nearest integer in downward direction ... |
How to turn an Image into a Link in HTML ? - GeeksforGeeks | 16 Dec, 2021
In this article, we will see how to turn an HTML image into a webpage link in HTML. The HTML <a> type attribute is used to create a hyperlink to web pages, files, locations on the same page. We can make elements like images into links by nesting them within an <a> element. It defines a hyperlink that is us... | [
{
"code": null,
"e": 25400,
"s": 25372,
"text": "\n16 Dec, 2021"
},
{
"code": null,
"e": 25834,
"s": 25400,
"text": "In this article, we will see how to turn an HTML image into a webpage link in HTML. The HTML <a> type attribute is used to create a hyperlink to web pages, files, ... |
Check if it is possible to create a polygon with a given angle - GeeksforGeeks | 03 May, 2021
Given an angle where, . The task is to check whether it is possible to make a regular polygon with all of its interior angle equal to . If possible then print “YES”, otherwise print “NO” (without quotes). Examples:
Input: angle = 90
Output: YES
Polygons with sides 4 is
possible with angle 90 degrees.
In... | [
{
"code": null,
"e": 25498,
"s": 25470,
"text": "\n03 May, 2021"
},
{
"code": null,
"e": 25715,
"s": 25498,
"text": "Given an angle where, . The task is to check whether it is possible to make a regular polygon with all of its interior angle equal to . If possible then print “YES... |
Find an array element such that all elements are divisible by it using c++ | Consider we have an array A with few elements. We have to find an element from A, such that all elements can be divided by it. Suppose the A is like [15, 21, 69, 33, 3, 72, 81], then the element will be 3, as all numbers can be divisible by 3.
To solve this problem, we will take the smallest number in A, then check whe... | [
{
"code": null,
"e": 1306,
"s": 1062,
"text": "Consider we have an array A with few elements. We have to find an element from A, such that all elements can be divided by it. Suppose the A is like [15, 21, 69, 33, 3, 72, 81], then the element will be 3, as all numbers can be divisible by 3."
},
{... |
Java Program to set title position in Java | To set title position, use the setTitlePosition() method in Java. Let’s say we have to position the title above the border's top line. For that, use the constant ABOVE_TOP for the border −
setTitlePosition(TitledBorder.ABOVE_TOP);
The following is an example to set title position −
package my;
import java.awt.BorderLay... | [
{
"code": null,
"e": 1251,
"s": 1062,
"text": "To set title position, use the setTitlePosition() method in Java. Let’s say we have to position the title above the border's top line. For that, use the constant ABOVE_TOP for the border −"
},
{
"code": null,
"e": 1293,
"s": 1251,
"t... |
Get your computer ready for machine learning: How, what and why you should use Anaconda, Miniconda and Conda | by Daniel Bourke | Towards Data Science | This article will go through what Anaconda is, what Minconda is and what Conda is, why you should know about them if you’re a data scientist or machine learning engineer and how you can use them.
Your computer is capable of running many different programs and applications. However, when you want to create or write your... | [
{
"code": null,
"e": 367,
"s": 171,
"text": "This article will go through what Anaconda is, what Minconda is and what Conda is, why you should know about them if you’re a data scientist or machine learning engineer and how you can use them."
},
{
"code": null,
"e": 600,
"s": 367,
... |
How to filter rows by excluding a particular value in columns of the R data frame? | To filter rows by excluding a particular value in columns of the data frame, we can use filter_all function of dplyr package along with all_vars argument that will select all the rows except the one that includes the passed value with negation. For example, if we have a data frame called df and we want to filter rows b... | [
{
"code": null,
"e": 1430,
"s": 1062,
"text": "To filter rows by excluding a particular value in columns of the data frame, we can use filter_all function of dplyr package along with all_vars argument that will select all the rows except the one that includes the passed value with negation. For exam... |
How to open chrome default profile with selenium? | We can open Chrome default profile with Selenium. To get the Chrome profile path, we need to input chrome://version/ in the Chrome browser and then press enter.
We need to use the ChromeOptions class to open the default Chrome profile. We need to use the add_argument method to specify the path of the Chrome profile.
o ... | [
{
"code": null,
"e": 1223,
"s": 1062,
"text": "We can open Chrome default profile with Selenium. To get the Chrome profile path, we need to input chrome://version/ in the Chrome browser and then press enter."
},
{
"code": null,
"e": 1380,
"s": 1223,
"text": "We need to use the Ch... |
Stacking Classifiers for Higher Predictive Performance | by Frank Ceballos | Towards Data Science | Purpose: The purpose of this article is to provide the reader with the necessary tools to implement the ensemble learning technique known as stacking.
Materials and methods: Using Scikit-learn, we generate a Madelon-like data set for a classification task. Then a Support Vector classifier (SVC), Nu-Support Vector class... | [
{
"code": null,
"e": 323,
"s": 172,
"text": "Purpose: The purpose of this article is to provide the reader with the necessary tools to implement the ensemble learning technique known as stacking."
},
{
"code": null,
"e": 827,
"s": 323,
"text": "Materials and methods: Using Scikit... |
Spring MVC - Error Handling Example | The following example shows how to use Error Handling and Validators in forms using the Spring Web MVC Framework. To start with, let us have a working Eclipse IDE in place and consider the following steps to develop a Dynamic Form based Web Application using the Spring Web Framework.
package com.tutorialspoint;
public... | [
{
"code": null,
"e": 3076,
"s": 2791,
"text": "The following example shows how to use Error Handling and Validators in forms using the Spring Web MVC Framework. To start with, let us have a working Eclipse IDE in place and consider the following steps to develop a Dynamic Form based Web Application ... |
Python Pandas - Fill NaN values using an interpolation method | Use the interpolate() method to fill NaN values. Let’s say the following is our CSV file opened in Microsoft Excel with some NaN values −
Load data from a CSV file into a Pandas DataFrame −
dataFrame = pd.read_csv("C:\\Users\\amit_\\Desktop\\SalesData.csv")
Fill NaN values with interpolate() −
dataFrame.interpolate()
F... | [
{
"code": null,
"e": 1200,
"s": 1062,
"text": "Use the interpolate() method to fill NaN values. Let’s say the following is our CSV file opened in Microsoft Excel with some NaN values −"
},
{
"code": null,
"e": 1252,
"s": 1200,
"text": "Load data from a CSV file into a Pandas Data... |
java.time.LocalDate.compareTo() Method Example | The java.time.LocalDate.compareTo(ChronoLocalDate other) method compares this date to another date.
Following is the declaration for java.time.LocalDate.compareTo(ChronoLocalDate other) method.
public int compareTo(ChronoLocalDate other)
other − the other date to compare to, not null.
the comparator value, negative if... | [
{
"code": null,
"e": 2015,
"s": 1915,
"text": "The java.time.LocalDate.compareTo(ChronoLocalDate other) method compares this date to another date."
},
{
"code": null,
"e": 2109,
"s": 2015,
"text": "Following is the declaration for java.time.LocalDate.compareTo(ChronoLocalDate oth... |
Predicting Titanic Survivors Using Data Science and Machine Learning | Towards Data Science | The purpose of this challenge is to predict the survivals and deaths of the Titanic disaster at the beginning of the 20th century. We will use two machine learning algorithms for this task, K-nearest neighbours classifier (KNN) and Decision Tree classifier. We will perform basic data clean and feature engineering and c... | [
{
"code": null,
"e": 535,
"s": 171,
"text": "The purpose of this challenge is to predict the survivals and deaths of the Titanic disaster at the beginning of the 20th century. We will use two machine learning algorithms for this task, K-nearest neighbours classifier (KNN) and Decision Tree classifie... |
How to fully change the color of a Tkinter Listbox? | Tkinter Listbox widgets are very useful in the case of representing a large set of data items in form of list items. To configure the properties such as change the background color of the entire Listbox, we can use configure(**options) method to change the properties of the Listbox widget.
# Import the required librari... | [
{
"code": null,
"e": 1353,
"s": 1062,
"text": "Tkinter Listbox widgets are very useful in the case of representing a large set of data items in form of list items. To configure the properties such as change the background color of the entire Listbox, we can use configure(**options) method to change ... |
How to use a global variable in a Python function? | The terms, global and local correspond to a variable's reach within a script or program. A global variable is one that can be accessed anywhere. A local variable can be accessed only within its frame. A local variable cannot be accessed globally.
Global variables are the one that are defined and declared outside a func... | [
{
"code": null,
"e": 1309,
"s": 1062,
"text": "The terms, global and local correspond to a variable's reach within a script or program. A global variable is one that can be accessed anywhere. A local variable can be accessed only within its frame. A local variable cannot be accessed globally."
},
... |
Limited-Memory Broyden-Fletcher-Goldfarb-Shanno Algorithm in ML.NET | by Robert Krzaczyński | Towards Data Science | Some time ago I published an article about the implementation of Naive Bayes using ML.NET. Continuing this series today I would like to introduce you to the Limited-Memory Broyden-Fletcher-Goldfarb-Shanno method. I will start with a theory and an explanation of what this method is about and what it is used for.
Some fa... | [
{
"code": null,
"e": 484,
"s": 171,
"text": "Some time ago I published an article about the implementation of Naive Bayes using ML.NET. Continuing this series today I would like to introduce you to the Limited-Memory Broyden-Fletcher-Goldfarb-Shanno method. I will start with a theory and an explanat... |
Spring Boot & H2 - Console | As in previous chapter Application Setup, we've created the required files in spring boot project. Now let's update the application.properties lying in src/main/resources and pom.xml to use a different version of maven-resources-plugin.
application.properties
spring.datasource.url=jdbc:h2:mem:testdb
pom.xml
...
<build... | [
{
"code": null,
"e": 2333,
"s": 2096,
"text": "As in previous chapter Application Setup, we've created the required files in spring boot project. Now let's update the application.properties lying in src/main/resources and pom.xml to use a different version of maven-resources-plugin."
},
{
"c... |
Program to Reverse a String using Pointers - GeeksforGeeks | 12 Jan, 2019
Given a string, the task is to reverse this String using pointers.
Examples:
Input: Geeks
Output: skeeG
Input: GeeksForGeeks
Output: skeeGroFskeeG
Approach: This method involves taking two pointers, one that points at the start of the string and the other at the end of the string. The characters are then... | [
{
"code": null,
"e": 24498,
"s": 24470,
"text": "\n12 Jan, 2019"
},
{
"code": null,
"e": 24565,
"s": 24498,
"text": "Given a string, the task is to reverse this String using pointers."
},
{
"code": null,
"e": 24575,
"s": 24565,
"text": "Examples:"
},
{
... |
Topic Modeling in Power BI using PyCaret | by Moez Ali | Towards Data Science | In our last post, we demonstrated how to implement clustering analysis in Power BI by integrating it with PyCaret, thus allowing analysts and data scientists to add a layer of machine learning to their reports and dashboards without any additional license costs.
In this post, we will see how we can implement topic mode... | [
{
"code": null,
"e": 434,
"s": 171,
"text": "In our last post, we demonstrated how to implement clustering analysis in Power BI by integrating it with PyCaret, thus allowing analysts and data scientists to add a layer of machine learning to their reports and dashboards without any additional license... |
Display text on an OpenCV window by using the function putText() | In this program, we will write text on an image using the opencv function putText(). This function takes in the image, font, coordinates of where to put the text, color, thickness, etc.
Step 1: Import cv2
Step 2: Define the parameters for the puttext( ) function.
Step 3: Pass the parameters in to the puttext() function... | [
{
"code": null,
"e": 1248,
"s": 1062,
"text": "In this program, we will write text on an image using the opencv function putText(). This function takes in the image, font, coordinates of where to put the text, color, thickness, etc."
},
{
"code": null,
"e": 1411,
"s": 1248,
"text... |
Angular7 - Forms | In this chapter, we will see how forms are used in Angular 7. We will discuss two ways of working with forms −
Template driven form
Model driven form
With a template driven form, most of the work is done in the template. With the model driven form, most of the work is done in the component class.
Let us now consider wo... | [
{
"code": null,
"e": 2172,
"s": 2061,
"text": "In this chapter, we will see how forms are used in Angular 7. We will discuss two ways of working with forms −"
},
{
"code": null,
"e": 2193,
"s": 2172,
"text": "Template driven form"
},
{
"code": null,
"e": 2211,
"s"... |
BeanFactory Example in Spring - 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
In order to instantiate the Spring core conta... | [
{
"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,
... |
C# Program to Delete an Empty and a Non-Empty Directory - GeeksforGeeks | 30 Nov, 2021
Given a directory(empty or non-empty), now we have to delete the given directory. Here, an empty directory means the directory is present without any files or subdirectories. We can define a directory as a collection of files and subdirectories, a directory may have data or not contain no data. The non-emp... | [
{
"code": null,
"e": 23911,
"s": 23883,
"text": "\n30 Nov, 2021"
},
{
"code": null,
"e": 24411,
"s": 23911,
"text": "Given a directory(empty or non-empty), now we have to delete the given directory. Here, an empty directory means the directory is present without any files or subd... |
Name Your Favorite Excel Function and I’ll Teach You its Pandas Equivalent | by Britt | Towards Data Science | So since no one has named one yet, I’ll start! One of my favorite excel formulas to date is a Match function that is nested in an Index function. But before I teach you its Pandas equivalent, let’s get some background on the INDEX/MATCH function and why it’s better than a VLOOKUP.
Two reasons why INDEX/MATCH is better ... | [
{
"code": null,
"e": 454,
"s": 172,
"text": "So since no one has named one yet, I’ll start! One of my favorite excel formulas to date is a Match function that is nested in an Index function. But before I teach you its Pandas equivalent, let’s get some background on the INDEX/MATCH function and why i... |
Combine Multiple Excel Worksheets Into a Single Pandas Dataframe - GeeksforGeeks | 05 Sep, 2020
Prerequisites: Working with excel files using Pandas
In these articles, we will discuss how to Import multiple excel sheet into a single DataFrame and save into a new excel file. Let’s suppose we have two Excel files with the same structure (Excel_1.xlsx, Excel_2.xlsx), then merge both of the sheets into a... | [
{
"code": null,
"e": 25054,
"s": 25026,
"text": "\n05 Sep, 2020"
},
{
"code": null,
"e": 25107,
"s": 25054,
"text": "Prerequisites: Working with excel files using Pandas"
},
{
"code": null,
"e": 25378,
"s": 25107,
"text": "In these articles, we will discuss ho... |
Drawing an image in canvas using in JavaScript | Following is the code for drawing an image in canvas using 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, sa... | [
{
"code": null,
"e": 1134,
"s": 1062,
"text": "Following is the code for drawing an image in canvas using JavaScript −"
},
{
"code": null,
"e": 1145,
"s": 1134,
"text": " Live Demo"
},
{
"code": null,
"e": 2167,
"s": 1145,
"text": "<DOCTYPE html>\n<html lang=\... |
Find objects between two dates in MongoDB? | Use operator gteandlt to find objects between two dates in MongoDB. To understand these
operators, let us create a collection.
Creating a collection here:
>db.order.insert({"OrderId":1,"OrderAddrees":"US","OrderDateTime":ISODate("2019-02-19")};
WriteResult({ "nInserted" : 1 })
>db.order.insert({"OrderId":2,"OrderAddre... | [
{
"code": null,
"e": 1189,
"s": 1062,
"text": "Use operator gteandlt to find objects between two dates in MongoDB. To understand these\noperators, let us create a collection."
},
{
"code": null,
"e": 1217,
"s": 1189,
"text": "Creating a collection here:"
},
{
"code": null... |
iText - Tiling PDF Pages | The following Java program demonstrates how to tile the contents of a PDF page to different pages using the iText library. It creates a PDF document with the name tilingPdfPages.pdf and saves it in the path C:/itextExamples/.
Save this code in a file with the name TilingPDFPages.java.
import com.itextpdf.kernel.geom.Af... | [
{
"code": null,
"e": 2594,
"s": 2368,
"text": "The following Java program demonstrates how to tile the contents of a PDF page to different pages using the iText library. It creates a PDF document with the name tilingPdfPages.pdf and saves it in the path C:/itextExamples/."
},
{
"code": null,... |
How to create a sphere in R? | To create a sphere, we can use spheres3d function of rgl package. The rgl package is specifically designed to create real-time interactive 3D plots. If we want to create a sphere then we need to pass the values for the three axes and the radius of the sphere. We can also change the color of the sphere by introducing co... | [
{
"code": null,
"e": 1422,
"s": 1062,
"text": "To create a sphere, we can use spheres3d function of rgl package. The rgl package is specifically designed to create real-time interactive 3D plots. If we want to create a sphere then we need to pass the values for the three axes and the radius of the s... |
Binary Search Program in C | Binary search is a fast search algorithm with run-time complexity of Ο(log n). This search algorithm works on the principle of divide and conquer. For this algorithm to work properly, the data collection should be in a sorted form.
#include <stdio.h>
#define MAX 20
// array of items on which linear search will be con... | [
{
"code": null,
"e": 2812,
"s": 2580,
"text": "Binary search is a fast search algorithm with run-time complexity of Ο(log n). This search algorithm works on the principle of divide and conquer. For this algorithm to work properly, the data collection should be in a sorted form."
},
{
"code":... |
Python Group by matching second tuple value in list of tuples | In this tutorial, we are going to write a program that groups all the tuples from a list that have same element as a second element. Let's see an example to understand it clearly.
[('Python', 'tutorialspoints'), ('Management', 'other'), ('Django', 'tutorialspoints'), ('React',
'tutorialspoints'), ('Social', 'other'), (... | [
{
"code": null,
"e": 1242,
"s": 1062,
"text": "In this tutorial, we are going to write a program that groups all the tuples from a list that have same element as a second element. Let's see an example to understand it clearly."
},
{
"code": null,
"e": 1404,
"s": 1242,
"text": "[(... |
MySQL query to return all records with a datetime older than 1 week | To get dates older than 1 week, you can use the following syntax −
select *from yourTableName where yourColumnName < now() - interval 1 week;
To understand the above concept, let us create a table. The query to create a table is as follows −
mysql> create table DatesOfOneWeek
−> (
−> ArrivalTime datetime
−> );... | [
{
"code": null,
"e": 1129,
"s": 1062,
"text": "To get dates older than 1 week, you can use the following syntax −"
},
{
"code": null,
"e": 1204,
"s": 1129,
"text": "select *from yourTableName where yourColumnName < now() - interval 1 week;"
},
{
"code": null,
"e": 130... |
jQuery - Widget AutoComplete | The Widget AutoComplete function can be used with widgets in JqueryUI.The Autocomplete widgets provides suggestions while you type into the field.For suppose give Ja as an input, it will provides an output as Java or JavaScript.
Here is the simple syntax to use Autocomplete −
$( "#tags" ).autocomplete({
source: avai... | [
{
"code": null,
"e": 2551,
"s": 2322,
"text": "The Widget AutoComplete function can be used with widgets in JqueryUI.The Autocomplete widgets provides suggestions while you type into the field.For suppose give Ja as an input, it will provides an output as Java or JavaScript."
},
{
"code": nu... |
Least number to be added to or subtracted from N to make it a Perfect Square - GeeksforGeeks | 20 May, 2021
Given a number N, find the minimum number that needs to be added to or subtracted from N, to make it a perfect square. If the number is to be added, print it with a + sign, else if the number is to be subtracted, print it with a – sign.
Examples:
Input: N = 14 Output: 2 Nearest perfect square before 14 =... | [
{
"code": null,
"e": 24692,
"s": 24664,
"text": "\n20 May, 2021"
},
{
"code": null,
"e": 24929,
"s": 24692,
"text": "Given a number N, find the minimum number that needs to be added to or subtracted from N, to make it a perfect square. If the number is to be added, print it with ... |
Data normalization in machine learning | by Mahbubul Alam | Towards Data Science | I wrote about cluster analysis in the previous article (Clustering: concepts, tools and algorithms), where I had a short discussion on data normalization. I touched upon how data normalization impacts clustering, and unsupervised algorithms generally.
But I felt that I missed the opportunity to go into more details. Bu... | [
{
"code": null,
"e": 424,
"s": 172,
"text": "I wrote about cluster analysis in the previous article (Clustering: concepts, tools and algorithms), where I had a short discussion on data normalization. I touched upon how data normalization impacts clustering, and unsupervised algorithms generally."
... |
Instant query() Method in Java with Examples - GeeksforGeeks | 08 Jan, 2019
query() method of an Instant class used to query this instant using the specified query as parameter.The TemporalQuery object passed as parameter define the logic to be used to obtain the result from this instant.
Syntax:
public <R> R query(TemporalQuery<R> query)
Parameters: This method accepts only one ... | [
{
"code": null,
"e": 24125,
"s": 24097,
"text": "\n08 Jan, 2019"
},
{
"code": null,
"e": 24339,
"s": 24125,
"text": "query() method of an Instant class used to query this instant using the specified query as parameter.The TemporalQuery object passed as parameter define the logic ... |
Plagiarism Detection in Online Exams using Machine Learning | by Christopher Gerling | Towards Data Science | During the Covid-19 pandemic, many educational institutions have been forced to provide home schooling. This includes alternative examination methods for schools and universities. A traditional exam is written in person under permanent surveillance of educational staff. However, online teaching and examinations can fai... | [
{
"code": null,
"e": 1058,
"s": 165,
"text": "During the Covid-19 pandemic, many educational institutions have been forced to provide home schooling. This includes alternative examination methods for schools and universities. A traditional exam is written in person under permanent surveillance of ed... |
Construct a Decision Tree and How to Deal with Overfitting | by Jun M. | Towards Data Science | A decision tree is an algorithm for supervised learning. It uses a tree structure, in which there are two types of nodes: decision node and leaf node. A decision node splits the data into two branches by asking a boolean question on a feature. A leaf node represents a class. The training process is about finding the “b... | [
{
"code": null,
"e": 673,
"s": 172,
"text": "A decision tree is an algorithm for supervised learning. It uses a tree structure, in which there are two types of nodes: decision node and leaf node. A decision node splits the data into two branches by asking a boolean question on a feature. A leaf node... |
SQLite - Subqueries | A Subquery or Inner query or Nested query is a query within another SQLite query and embedded within the WHERE clause.
A subquery is used to return data that will be used in the main query as a condition to further restrict the data to be retrieved.
Subqueries can be used with the SELECT, INSERT, UPDATE, and DELETE sta... | [
{
"code": null,
"e": 2757,
"s": 2638,
"text": "A Subquery or Inner query or Nested query is a query within another SQLite query and embedded within the WHERE clause."
},
{
"code": null,
"e": 2888,
"s": 2757,
"text": "A subquery is used to return data that will be used in the main... |
Access Modifiers in C++ - GeeksforGeeks | 22 Apr, 2021
Access modifiers are used to implement an important aspect of Object-Oriented Programming known as Data Hiding. Consider a real-life example: The Research and analysis wing (R&AW), having 10 core members has come in possession of sensitive confidential information regarding national security. Now we can co... | [
{
"code": null,
"e": 24078,
"s": 24050,
"text": "\n22 Apr, 2021"
},
{
"code": null,
"e": 25528,
"s": 24078,
"text": "Access modifiers are used to implement an important aspect of Object-Oriented Programming known as Data Hiding. Consider a real-life example: The Research and anal... |
How do I declare and initialize an array in Java? | You can declare an array just like a variable −
int myArray[];
You can create an array just like an object using the new keyword −
myArray = new int[5];
You can initialize the array by assigning values to all the elements one by one using the index −
myArray [0] = 101;
myArray [1] = 102;
You can access the array elemen... | [
{
"code": null,
"e": 1110,
"s": 1062,
"text": "You can declare an array just like a variable −"
},
{
"code": null,
"e": 1125,
"s": 1110,
"text": "int myArray[];"
},
{
"code": null,
"e": 1193,
"s": 1125,
"text": "You can create an array just like an object usin... |
How to clear all elements from List in Python - 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
The Python clear() method is used to clear al... | [
{
"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,
... |
TypeScript - Array some() | some() method tests whether some element in the array passes the test implemented by the provided function.
array.some(callback[, thisObject]);
callback − Function to test for each element.
callback − Function to test for each element.
thisObject − Object to use as this when executing callback.
thisObject − Object to ... | [
{
"code": null,
"e": 2156,
"s": 2048,
"text": "some() method tests whether some element in the array passes the test implemented by the provided function."
},
{
"code": null,
"e": 2193,
"s": 2156,
"text": "array.some(callback[, thisObject]);\n"
},
{
"code": null,
"e":... |
Keywords in Java | Keywords in Java are reserved words that represent predefined actions, internal processes etc. Because of this, keywords cannot be used as names of variables, functions, objects etc.
The main difference between keywords and identifiers is that keywords are reserved words that represent predefined actions while identifi... | [
{
"code": null,
"e": 1245,
"s": 1062,
"text": "Keywords in Java are reserved words that represent predefined actions, internal processes etc. Because of this, keywords cannot be used as names of variables, functions, objects etc."
},
{
"code": null,
"e": 1438,
"s": 1245,
"text": ... |
time.Now() Function in Golang With Examples - GeeksforGeeks | 21 Apr, 2020
In Go language, time packages supplies functionality for determining as well as viewing time. The Now() function in Go language is used to find the current local time. Moreover, this function is defined under the time package. Here, you need to import the “time” package in order to use these functions.
Syn... | [
{
"code": null,
"e": 25813,
"s": 25785,
"text": "\n21 Apr, 2020"
},
{
"code": null,
"e": 26117,
"s": 25813,
"text": "In Go language, time packages supplies functionality for determining as well as viewing time. The Now() function in Go language is used to find the current local t... |
H2 Database - Commit | COMMIT is a command from the SQL grammar used to commit the transaction. We can either commit the specific transaction or we can commit the currently executed transaction.
There are two different syntaxes for COMMIT command.
Following is the generic syntax for the commit command to commit the current transaction.
COMMI... | [
{
"code": null,
"e": 2279,
"s": 2107,
"text": "COMMIT is a command from the SQL grammar used to commit the transaction. We can either commit the specific transaction or we can commit the currently executed transaction."
},
{
"code": null,
"e": 2332,
"s": 2279,
"text": "There are ... |
Check if a number is perfect square without finding square root in C++ | Suppose a number is given, we have to check whether the number is a perfect square or not. We will not use the square root operation to check it. Suppose a number 1024 is there, this is a perfect square, but 1000 is not a perfect square. The logic is simple, we have to follow this algorithm to get the result.
isPerfect... | [
{
"code": null,
"e": 1373,
"s": 1062,
"text": "Suppose a number is given, we have to check whether the number is a perfect square or not. We will not use the square root operation to check it. Suppose a number 1024 is there, this is a perfect square, but 1000 is not a perfect square. The logic is si... |
From soup to nuts guide for setting up a conda environment | by Ebru Cucen | Towards Data Science | Hello! Conda is one of the most popular tools at data science community, and yet, it can be confusing to understand the steps and the cost of implementing that step, as there is hardly a single place explains, so I decided to write one up.
I will focus on three topics, the first one is about conda installer options, An... | [
{
"code": null,
"e": 412,
"s": 172,
"text": "Hello! Conda is one of the most popular tools at data science community, and yet, it can be confusing to understand the steps and the cost of implementing that step, as there is hardly a single place explains, so I decided to write one up."
},
{
"... |
\qquad - Tex Command | \qquad - Used to create 2em space.
{ \qquad}
\qquad command creates 2em space.
|\qquad\hphantom{|}|
|||
|\qquad\hphantom{|}|
|||
|\qquad\hphantom{|}|
14 Lectures
52 mins
Ashraf Said
11 Lectures
1 hours
Ashraf Said
9 Lectures
1 hours
Emenwa Global, Ejike IfeanyiChukwu
... | [
{
"code": null,
"e": 8021,
"s": 7986,
"text": "\\qquad - Used to create 2em space."
},
{
"code": null,
"e": 8031,
"s": 8021,
"text": "{ \\qquad}"
},
{
"code": null,
"e": 8065,
"s": 8031,
"text": "\\qquad command creates 2em space."
},
{
"code": null,
... |
Find a pair with given target in BST | Practice | GeeksforGeeks | Given a Binary Search Tree and a target sum. Check whether there's a pair of Nodes in the BST with value summing up to the target sum.
Example 1:
Input:
2
/ \
1 3
sum = 5
Output: 1
Explanation:
Nodes with value 2 and 3 sum up to 5.
Example 2:
Input:
6
/
5 ... | [
{
"code": null,
"e": 374,
"s": 238,
"text": "Given a Binary Search Tree and a target sum. Check whether there's a pair of Nodes in the BST with value summing up to the target sum. "
},
{
"code": null,
"e": 385,
"s": 374,
"text": "Example 1:"
},
{
"code": null,
"e": 49... |
Solidity - Interfaces | Interfaces are similar to abstract contracts and are created using interface keyword. Following are the key characteristics of an interface.
Interface can not have any function with implementation.
Interface can not have any function with implementation.
Functions of an interface can be only of type external.
Functions... | [
{
"code": null,
"e": 2696,
"s": 2555,
"text": "Interfaces are similar to abstract contracts and are created using interface keyword. Following are the key characteristics of an interface."
},
{
"code": null,
"e": 2753,
"s": 2696,
"text": "Interface can not have any function with ... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.