title stringlengths 3 221 | text stringlengths 17 477k | parsed listlengths 0 3.17k |
|---|---|---|
Katz Centrality (Centrality Measure) - GeeksforGeeks | 24 Nov, 2021
In graph theory, the Katz centrality of a node is a measure of centrality in a network. It was introduced by Leo Katz in 1953 and is used to measure the relative degree of influence of an actor (or node) within a social network. Unlike typical centrality measures which consider only the shortest path (the ... | [
{
"code": null,
"e": 26305,
"s": 26277,
"text": "\n24 Nov, 2021"
},
{
"code": null,
"e": 26758,
"s": 26305,
"text": "In graph theory, the Katz centrality of a node is a measure of centrality in a network. It was introduced by Leo Katz in 1953 and is used to measure the relative d... |
Content Spoofing - GeeksforGeeks | 23 Oct, 2018
Content Spoofing (also known as Content Injection) is one of the common web security vulnerability. It allows end user of the vulnerable web application to spoof or modify the actual content on the web page. The user might use the security loopholes in the website to inject the content that he/she wishes t... | [
{
"code": null,
"e": 26273,
"s": 26245,
"text": "\n23 Oct, 2018"
},
{
"code": null,
"e": 26789,
"s": 26273,
"text": "Content Spoofing (also known as Content Injection) is one of the common web security vulnerability. It allows end user of the vulnerable web application to spoof o... |
Difference between != and !== operator in JavaScript - GeeksforGeeks | 07 Aug, 2019
!= operatorThe inequality operator (!=) is the logical opposite of the equality operator. It means “Not Equal” and returns true where equality would return false and vice versa.Like the equality operator, the inequality operator will convert data types of values while comparing.For example 1 != ‘1’ will re... | [
{
"code": null,
"e": 26545,
"s": 26517,
"text": "\n07 Aug, 2019"
},
{
"code": null,
"e": 26936,
"s": 26545,
"text": "!= operatorThe inequality operator (!=) is the logical opposite of the equality operator. It means “Not Equal” and returns true where equality would return false a... |
Euler's Factorization method - GeeksforGeeks | 12 Jul, 2021
Given a number N, the task is to find the factors of N. Examples:
Input: N = 1000009 Output: 293 3413 Explanation: 293 * 3413 = 1000009Input: N = 100000 Output: 800 125 Explanation: 800 * 125 = 100000
Euler’s Factorization method: Euler’s factorization method works on the principle that all the numbers... | [
{
"code": null,
"e": 25781,
"s": 25753,
"text": "\n12 Jul, 2021"
},
{
"code": null,
"e": 25849,
"s": 25781,
"text": "Given a number N, the task is to find the factors of N. Examples: "
},
{
"code": null,
"e": 25986,
"s": 25849,
"text": "Input: N = 1000009 Out... |
Understanding the Execution of Python Program - GeeksforGeeks | 10 Jul, 2020
This article aims at providing a detailed insight into the execution of the Python program. Let’s consider the below example.
Example:
Python3
a = 10b = 10print("Sum ", (a+b))
Output:
Sum 20
Suppose the above python program is saved as first.py. Here first is the name and .py is the extension. The executi... | [
{
"code": null,
"e": 25351,
"s": 25323,
"text": "\n10 Jul, 2020"
},
{
"code": null,
"e": 25477,
"s": 25351,
"text": "This article aims at providing a detailed insight into the execution of the Python program. Let’s consider the below example."
},
{
"code": null,
"e": ... |
Divide and Conquer - GeeksforGeeks | 06 May, 2017
Maximum Subarray Sum problem is to find the subarray with maximum sum. For example, given an array {12, -13, -5, 25, -20, 30, 10}, the maximum subarray sum is 45. The naive solution for this problem is to calculate sum of all subarrays starting with every element and return the maximum of all. We can solve... | [
{
"code": null,
"e": 35737,
"s": 35709,
"text": "\n06 May, 2017"
},
{
"code": null,
"e": 36146,
"s": 35737,
"text": "Maximum Subarray Sum problem is to find the subarray with maximum sum. For example, given an array {12, -13, -5, 25, -20, 30, 10}, the maximum subarray sum is 45. ... |
Python | Initialize tuples with parameters - GeeksforGeeks | 15 Oct, 2019
This article deals with initializing the tuples with parameters. Namely, default value, size, and specific value at specific index. Let’s discuss certain ways in which this task can be performed.
Method #1 : Using tuple() + * operatorThis task can be performed using combination of above functionalities. In... | [
{
"code": null,
"e": 25555,
"s": 25527,
"text": "\n15 Oct, 2019"
},
{
"code": null,
"e": 25751,
"s": 25555,
"text": "This article deals with initializing the tuples with parameters. Namely, default value, size, and specific value at specific index. Let’s discuss certain ways in w... |
Python | Customer Churn Analysis Prediction - GeeksforGeeks | 23 Mar, 2020
Customer ChurnIt is when an existing customer, user, subscriber, or any kind of return client stops doing business or ends the relationship with a company.
Types of Customer Churn –
Contractual Churn : When a customer is under a contract for a service and decides to cancel the service e.g. Cable TV, SaaS.
... | [
{
"code": null,
"e": 25589,
"s": 25561,
"text": "\n23 Mar, 2020"
},
{
"code": null,
"e": 25745,
"s": 25589,
"text": "Customer ChurnIt is when an existing customer, user, subscriber, or any kind of return client stops doing business or ends the relationship with a company."
},
... |
How to display the bit(1) fields in MySQL? | Let us first create a table. Here, our columns is of type bit(1) −
mysql> create table DemoTable
(
isCaptured bit(1)
);
Query OK, 0 rows affected (1.00 sec)
Insert some records in the table using insert command −
mysql> insert into DemoTable values(0);
Query OK, 1 row affected (0.26 sec)
mysql> insert into DemoTable... | [
{
"code": null,
"e": 1129,
"s": 1062,
"text": "Let us first create a table. Here, our columns is of type bit(1) −"
},
{
"code": null,
"e": 1222,
"s": 1129,
"text": "mysql> create table DemoTable\n(\n isCaptured bit(1)\n);\nQuery OK, 0 rows affected (1.00 sec)"
},
{
"cod... |
Field getName() method in Java with Examples - GeeksforGeeks | 26 Aug, 2019
The getName() method of java.lang.reflect.Field used to get the name of the field represented by this Field object. When a class contains a field and we want to get the name of that field then we can use this method to return the name of Field.
Syntax:
public String getName()
Parameters: This method accep... | [
{
"code": null,
"e": 23948,
"s": 23920,
"text": "\n26 Aug, 2019"
},
{
"code": null,
"e": 24193,
"s": 23948,
"text": "The getName() method of java.lang.reflect.Field used to get the name of the field represented by this Field object. When a class contains a field and we want to ge... |
Apache Commons CLI - Usage Example | Apache Commons CLI provides HelpFormatter class to print the usage guide of command line arguments. See the example given below −
CLITester.java
import org.apache.commons.cli.HelpFormatter;
import org.apache.commons.cli.Options;
import org.apache.commons.cli.ParseException;
public class CLITester {
public static vo... | [
{
"code": null,
"e": 1849,
"s": 1719,
"text": "Apache Commons CLI provides HelpFormatter class to print the usage guide of command line arguments. See the example given below −"
},
{
"code": null,
"e": 1864,
"s": 1849,
"text": "CLITester.java"
},
{
"code": null,
"e": ... |
Jazz music generation using GPT. The GPT model has achieved astonishing... | by Viet Pham | Towards Data Science | The Generative Pre-trained Transformer or GPT model has achieved astonishing results when dealing with Natural Language Processing (NLP) tasks. However, the model architecture is not exclusive to NLP and has been utilised to solves other problem such as time-series prediction or music generation. In this article, I wil... | [
{
"code": null,
"e": 619,
"s": 171,
"text": "The Generative Pre-trained Transformer or GPT model has achieved astonishing results when dealing with Natural Language Processing (NLP) tasks. However, the model architecture is not exclusive to NLP and has been utilised to solves other problem such as t... |
How to find the value of a button with JavaScript? | Use the value property to get the value of a button in JavaScript.
You can try to run the following code to find the value of a button −
Live Demo
<!DOCTYPE html>
<html>
<body>
<form id="myForm">
<button id="btn" type="button" value="my_button">My Button</button>
</form>
<script>
... | [
{
"code": null,
"e": 1129,
"s": 1062,
"text": "Use the value property to get the value of a button in JavaScript."
},
{
"code": null,
"e": 1199,
"s": 1129,
"text": "You can try to run the following code to find the value of a button −"
},
{
"code": null,
"e": 1209,
... |
Date after adding given number of days to the given date - GeeksforGeeks | 07 May, 2021
Given a date and a positive integer x. The task is to find date after adding x days to the given date
Examples:
Input : d1 = 14, m1 = 5, y1 = 2017
Days to be added x = 10
Output : d2 = 24, m2 = 5, y2 = 2017
Input : d1 = 14, m1 = 3, y1 = 2015
Days to be added x = 466
Output : d2 = 14, m2 =... | [
{
"code": null,
"e": 25106,
"s": 25078,
"text": "\n07 May, 2021"
},
{
"code": null,
"e": 25208,
"s": 25106,
"text": "Given a date and a positive integer x. The task is to find date after adding x days to the given date"
},
{
"code": null,
"e": 25219,
"s": 25208,
... |
C Program for Iterative Merge Sort | Merge sort what is a sorting algorithm based on the divide and conquer technique. the time complexity of merge sort is O(n log n). The algorithm first divides the array into equal halves and then merges them in a certain manner.
In iterative merge sort, we will divide the elements into equal halves using a recursive ap... | [
{
"code": null,
"e": 1291,
"s": 1062,
"text": "Merge sort what is a sorting algorithm based on the divide and conquer technique. the time complexity of merge sort is O(n log n). The algorithm first divides the array into equal halves and then merges them in a certain manner."
},
{
"code": nu... |
How to create a collapsed border in HTML? | To create a collapsed border in HTML, use the border-collapse CSS property. This property can have the following values:
Here’s how you can add,
You can try to run the following code to create collapsed border with property collapse:
Live Demo
<!DOCTYPE html>
<html>
<head>
<style>
table {border-collap... | [
{
"code": null,
"e": 1183,
"s": 1062,
"text": "To create a collapsed border in HTML, use the border-collapse CSS property. This property can have the following values:"
},
{
"code": null,
"e": 1207,
"s": 1183,
"text": "Here’s how you can add,"
},
{
"code": null,
"e": ... |
NumPy - Data Types | NumPy supports a much greater variety of numerical types than Python does. The following table shows different scalar data types defined in NumPy.
bool_
Boolean (True or False) stored as a byte
int_
Default integer type (same as C long; normally either int64 or int32)
intc
Identical to C int (normally int32 or int64)
i... | [
{
"code": null,
"e": 2390,
"s": 2243,
"text": "NumPy supports a much greater variety of numerical types than Python does. The following table shows different scalar data types defined in NumPy."
},
{
"code": null,
"e": 2396,
"s": 2390,
"text": "bool_"
},
{
"code": null,
... |
How to add custom message handlers to the pipeline in Asp.Net webAPI C#? | To create a custom Server-Side HTTP Message Handler in ASP.NET Web API, we need to create a class that must be derived from the System.Net.Http.DelegatingHandler.
Step 1 −
Create a controller and its corresponding action methods.
using DemoWebApplication.Models;
using System.Collections.Generic;
using System.Linq;
usin... | [
{
"code": null,
"e": 1225,
"s": 1062,
"text": "To create a custom Server-Side HTTP Message Handler in ASP.NET Web API, we need to create a class that must be derived from the System.Net.Http.DelegatingHandler."
},
{
"code": null,
"e": 1234,
"s": 1225,
"text": "Step 1 −"
},
{
... |
bash - Unix, Linux Command | Bash is intended to be a conformant implementation of the
Shell and Utilities portion of the IEEE POSIX specification
(IEEE Standard 1003.1).
Bash can be configured to be POSIX-conformant by default.
An interactive shell is one started without non-option arguments
and without the
-c option
whose standard input an... | [
{
"code": null,
"e": 10779,
"s": 10577,
"text": "\nBash is intended to be a conformant implementation of the\nShell and Utilities portion of the IEEE POSIX specification\n(IEEE Standard 1003.1).\nBash can be configured to be POSIX-conformant by default.\n"
},
{
"code": null,
"e": 11120,
... |
Rod Cutting | Practice | GeeksforGeeks | Given a rod of length N inches and an array of prices, price[] that contains prices of all pieces of size smaller than N. Determine the maximum value obtainable by cutting up the rod and selling the pieces.
Example 1:
Input:
N = 8
Price[] = {1, 5, 8, 9, 10, 17, 17, 20}
Output:
22
Explanation:
The maximum obtainable v... | [
{
"code": null,
"e": 445,
"s": 238,
"text": "Given a rod of length N inches and an array of prices, price[] that contains prices of all pieces of size smaller than N. Determine the maximum value obtainable by cutting up the rod and selling the pieces."
},
{
"code": null,
"e": 458,
"s... |
XAML - RichEditBox | A RichEditBox is a rich text editing control that supports formatted text, hyperlinks, and other rich content. WPF projects do not support this control. So it will be implemented in Windows App. The hierarchical inheritance of RichEditBox class is as follows −
AcceptsReturn
Gets or sets a value that indicates whether t... | [
{
"code": null,
"e": 2184,
"s": 1923,
"text": "A RichEditBox is a rich text editing control that supports formatted text, hyperlinks, and other rich content. WPF projects do not support this control. So it will be implemented in Windows App. The hierarchical inheritance of RichEditBox class is as fo... |
What is strtok_r() function in C language? | This function is similar to the strtok() function. The only key difference is that the _r, which is called as re-entrant function.
A re-entrant function is a function which can be interrupted during its execution. This type of function can be used to resume execution.
Because of this fact, re-entrant functions are thre... | [
{
"code": null,
"e": 1193,
"s": 1062,
"text": "This function is similar to the strtok() function. The only key difference is that the _r, which is called as re-entrant function."
},
{
"code": null,
"e": 1331,
"s": 1193,
"text": "A re-entrant function is a function which can be in... |
How to get computer's UTC offset in Python? | The computer's UTC offset is the timezone set on your computer. YOu can get this timezone information using the time module. time.timezone returns UTC offset in seconds.
import time
print(-time.timezone) # India's timezone: +5:30
This will give the output −
19800
You can also use other workarounds to get the timezone i... | [
{
"code": null,
"e": 1232,
"s": 1062,
"text": "The computer's UTC offset is the timezone set on your computer. YOu can get this timezone information using the time module. time.timezone returns UTC offset in seconds."
},
{
"code": null,
"e": 1292,
"s": 1232,
"text": "import time\... |
Predicting Customer Churn Using Logistic Regression | by Andrew Cole | Towards Data Science | In my previous post, we completed a pretty in-depth walk through of the exploratory data analysis process for a customer churn analysis dataset. Our data, sourced from Kaggle, is centered around customer churn, the rate at which a commercial customer will leave the commercial platform that they are currently a (paying)... | [
{
"code": null,
"e": 831,
"s": 172,
"text": "In my previous post, we completed a pretty in-depth walk through of the exploratory data analysis process for a customer churn analysis dataset. Our data, sourced from Kaggle, is centered around customer churn, the rate at which a commercial customer will... |
How to get summary statistics by group in R - GeeksforGeeks | 23 Aug, 2021
In this article, we will learn how to get summary statistics by the group in R programming language.
Sample dataframe in use:
grpBy num
1 A 20
2 A 30
3 A 40
4 B 50
5 B 50
6 C 70
7 C 80
8 C 25
9 C 35
10 D 45
11 E 55
12 E 65
13 E 75... | [
{
"code": null,
"e": 25242,
"s": 25214,
"text": "\n23 Aug, 2021"
},
{
"code": null,
"e": 25343,
"s": 25242,
"text": "In this article, we will learn how to get summary statistics by the group in R programming language."
},
{
"code": null,
"e": 25368,
"s": 25343,
... |
Split a URL in JavaScript after every forward slash? | To split a URL, use the split() method. Use toString() before that. Let us see an example
var newURL="http://www.example.com/index.html/homePage/aboutus/";
console.log(newURL);
var splitURL=newURL.toString().split("/");
console.log(splitURL);
Above, we have set forward slash in the split() function, since we need to sp... | [
{
"code": null,
"e": 1152,
"s": 1062,
"text": "To split a URL, use the split() method. Use toString() before that. Let us see an example"
},
{
"code": null,
"e": 1305,
"s": 1152,
"text": "var newURL=\"http://www.example.com/index.html/homePage/aboutus/\";\nconsole.log(newURL);\nv... |
Pivot Points calculation in Python for day trading | by Gianluca Malato | Towards Data Science | Day trading is very different from swing trading. It’s more difficult and it needs some particular tools to be profitable. Pivot Points are some of the tools that day traders can use.
In this article, I explain how they work.
Pivot points are price levels often used in intraday trading (but they can be used even in swi... | [
{
"code": null,
"e": 356,
"s": 172,
"text": "Day trading is very different from swing trading. It’s more difficult and it needs some particular tools to be profitable. Pivot Points are some of the tools that day traders can use."
},
{
"code": null,
"e": 398,
"s": 356,
"text": "In... |
C# | Getting an enumerator for a range of elements in the ArrayList - GeeksforGeeks | 02 Jul, 2019
ArrayList.GetEnumerator(Int32, Int32) method is used to get an enumerator for a range of elements in the ArrayList.
Syntax:
public virtual System.Collections.IEnumerator GetEnumerator (int index, int count);
Parameters:
index: It is the zero-based starting index of type Int32 of the ArrayList section that ... | [
{
"code": null,
"e": 23911,
"s": 23883,
"text": "\n02 Jul, 2019"
},
{
"code": null,
"e": 24027,
"s": 23911,
"text": "ArrayList.GetEnumerator(Int32, Int32) method is used to get an enumerator for a range of elements in the ArrayList."
},
{
"code": null,
"e": 24035,
... |
Python Lists and List Manipulation | by Michael Galarnyk | Towards Data Science | Before starting, I should mention that the code in this blog post and in the video above is available on my github.
Lists are written within square brackets []
# Define a listz = [3, 7, 4, 2]
Lists store an ordered collection of items which can be of different types. The list defined above has items that are all of the... | [
{
"code": null,
"e": 288,
"s": 172,
"text": "Before starting, I should mention that the code in this blog post and in the video above is available on my github."
},
{
"code": null,
"e": 332,
"s": 288,
"text": "Lists are written within square brackets []"
},
{
"code": null... |
Deploying a Scikit-Learn Model on AWS Using SKLearn Estimators, Local Jupyter Notebooks, and the Terminal | by Quinn Lanners | Towards Data Science | Amazon Web Services (AWS) is currently the most in-demand cloud platform for Data Science and Machine Learning professionals. Given this, the first collection of blog posts in this Machine Learning Deployment series will outline how to deploy various models in a number of different ways on AWS.
Other posts in this seri... | [
{
"code": null,
"e": 468,
"s": 172,
"text": "Amazon Web Services (AWS) is currently the most in-demand cloud platform for Data Science and Machine Learning professionals. Given this, the first collection of blog posts in this Machine Learning Deployment series will outline how to deploy various mode... |
Build your own custom scikit-learn Regression | by Dr. Robert Kübler | Towards Data Science | If Python is your programming language of choice for Data Science and Machine Learning, you have probably used the awesome scikit-learn library already. I’m a big fan of this project myself due to its consistent API: You define some object such as a regressor, you fit, you predict, done. It cannot get much easier than ... | [
{
"code": null,
"e": 498,
"s": 172,
"text": "If Python is your programming language of choice for Data Science and Machine Learning, you have probably used the awesome scikit-learn library already. I’m a big fan of this project myself due to its consistent API: You define some object such as a regre... |
Understanding Logistic Regression - GeeksforGeeks | 20 Apr, 2022
Pre-requisite: Linear Regression This article discusses the basics of Logistic Regression and its implementation in Python. Logistic regression is basically a supervised classification algorithm. In a classification problem, the target variable(or output), y, can take only discrete values for a given set o... | [
{
"code": null,
"e": 24125,
"s": 24097,
"text": "\n20 Apr, 2022"
},
{
"code": null,
"e": 24798,
"s": 24125,
"text": "Pre-requisite: Linear Regression This article discusses the basics of Logistic Regression and its implementation in Python. Logistic regression is basically a supe... |
Importance of return type in Java? | A return statement causes the program control to transfer back to the caller of a method. Every method in Java is declared with a return type and it is mandatory for all java methods. A return type may be a primitive type like int, float, double, a reference type or void type(returns nothing).
There are a few important... | [
{
"code": null,
"e": 1357,
"s": 1062,
"text": "A return statement causes the program control to transfer back to the caller of a method. Every method in Java is declared with a return type and it is mandatory for all java methods. A return type may be a primitive type like int, float, double, a refe... |
C/C++ Tokens? | C++ Tokens are the smallest individual units of a program.
C++ is the superset of C and so most constructs of C are legal in C++ with their meaning and usage unchanged. So tokens, expressions, and data types are similar to that of C.
Following are the C++ tokens : (most of c++ tokens are basically similar to the C toke... | [
{
"code": null,
"e": 1121,
"s": 1062,
"text": "C++ Tokens are the smallest individual units of a program."
},
{
"code": null,
"e": 1296,
"s": 1121,
"text": "C++ is the superset of C and so most constructs of C are legal in C++ with their meaning and usage unchanged. So tokens, ex... |
Multiply any Number with using Bitwise Operator in C++ | In this tutorial, we are going write a program that multiplies the given two numbers using bitwise operators.
The left shift (<<) operator is used for the multiplication whereas the right shift (>>) is used for the division.
The multiplication of two numbers x, y can be written as x * y = (x * 2) * (y / 2) if y is even... | [
{
"code": null,
"e": 1172,
"s": 1062,
"text": "In this tutorial, we are going write a program that multiplies the given two numbers using bitwise operators."
},
{
"code": null,
"e": 1287,
"s": 1172,
"text": "The left shift (<<) operator is used for the multiplication whereas the ... |
DDL Full Form - GeeksforGeeks | 13 Dec, 2021
DDL stands for Data Definition Language. These commands are used to change the structure of a database and database objects.For example, DDL commands can be used to add, remove, or modify tables with in a database.
The DDL commands are:
CREATEALTERDROPTRUNCATERENAME
CREATE
ALTER
DROP
TRUNCATE
RENAME
1. ... | [
{
"code": null,
"e": 23916,
"s": 23888,
"text": "\n13 Dec, 2021"
},
{
"code": null,
"e": 24132,
"s": 23916,
"text": "DDL stands for Data Definition Language. These commands are used to change the structure of a database and database objects.For example, DDL commands can be used t... |
C# - Operator Overloading | You can redefine or overload most of the built-in operators available in C#. Thus a programmer can use operators with user-defined types as well. Overloaded operators are functions with special names the keyword operator followed by the symbol for the operator being defined. similar to any other function, an overloaded... | [
{
"code": null,
"e": 2640,
"s": 2270,
"text": "You can redefine or overload most of the built-in operators available in C#. Thus a programmer can use operators with user-defined types as well. Overloaded operators are functions with special names the keyword operator followed by the symbol for the o... |
CNN Architectures, a Deep-dive. Implementing every popular CNN... | by Sai Kumar Basaveswara | Towards Data Science | In Deep Learning, a Convolutional Neural Network(CNN) is a class of deep neural networks, most commonly applied to analyzing visual imagery. Convolutional Neural Networks are state of the art models for Image Classification, Segmentation, Object Detection and many other image processing tasks. In order to get started i... | [
{
"code": null,
"e": 926,
"s": 172,
"text": "In Deep Learning, a Convolutional Neural Network(CNN) is a class of deep neural networks, most commonly applied to analyzing visual imagery. Convolutional Neural Networks are state of the art models for Image Classification, Segmentation, Object Detection... |
Online JSON Formatter | Editable JSON Code
12345678910111213141516{"Company": {"Employee": {"FirstName": "Tanmay","LastName": "Patil","ContactNo": "1234567890","Email": "tanmaypatil@xyz.com","Address": {"City": "Bangalore","State": "Karnataka","Zip": "560212"}}}}X
Privacy Policy
Cookies Policy
Terms of Use | [
{
"code": null,
"e": 19,
"s": 0,
"text": "Editable JSON Code"
},
{
"code": null,
"e": 241,
"s": 19,
"text": "12345678910111213141516{\"Company\": {\"Employee\": {\"FirstName\": \"Tanmay\",\"LastName\": \"Patil\",\"ContactNo\": \"1234567890\",\"Email\": \"tanmaypatil@xyz.com\",\"A... |
C++ Program to Calculate Power Using Recursion | The power of a number can be calculated as x^y where x is the number and y is its power.
For example.
Let’s say, x = 2 and y = 10
x^y =1024
Here, x^y is 2^10
A program to find the power using recursion is as follows.
Live Demo
#include <iostream>
using namespace std;
int FindPower(int base, int power) {
if (power =... | [
{
"code": null,
"e": 1151,
"s": 1062,
"text": "The power of a number can be calculated as x^y where x is the number and y is its power."
},
{
"code": null,
"e": 1164,
"s": 1151,
"text": "For example."
},
{
"code": null,
"e": 1220,
"s": 1164,
"text": "Let’s say... |
8085 program to find the set bit of accumulator - GeeksforGeeks | 13 May, 2019
Problem – All bits of an accumulator are 0 except a single bit which is 1. Write an assembly language program using 8085 to determine which bit of the accumulator is 1. The result should be a decimal number from 1 to 8 and is required to be stored in register C.
Examples –
Example 1 : Accumulator Content i... | [
{
"code": null,
"e": 24389,
"s": 24361,
"text": "\n13 May, 2019"
},
{
"code": null,
"e": 24652,
"s": 24389,
"text": "Problem – All bits of an accumulator are 0 except a single bit which is 1. Write an assembly language program using 8085 to determine which bit of the accumulator ... |
5 Categorical Encoding Tricks you need to know today as a data scientist | by Philippe Bouaziz,Data Scientist at Africa4Data,PhD | Towards Data Science | Categorical encoding is a fundamental step in exploratory data analysis (EDA) for most advanced data science projects whether your developing machine learning models or business analytics. Most libraries including scikit-learn use a variety of data encoding methods. Due to the high quantity of data, finding tricks for ... | [
{
"code": null,
"e": 768,
"s": 172,
"text": "Categorical encoding is a fundamental step in exploratory data analysis (EDA) for most advanced data science projects whether your developing machine learning models or business analytics. Most libraries including scikit-learn use a variety of data encodi... |
Android - NFC Guide | NFC stands for Near Field Communication, and as the name implies it provides a wireless communication mechanism between two compatible devices. NFC is a short range wireless technology having a range of 4cm or less for two devices to share data.
Like Bluetooth and WiFi, and all manner of other wireless signals, NFC wor... | [
{
"code": null,
"e": 3853,
"s": 3607,
"text": "NFC stands for Near Field Communication, and as the name implies it provides a wireless communication mechanism between two compatible devices. NFC is a short range wireless technology having a range of 4cm or less for two devices to share data."
},
... |
Concatenating variable number of arrays into one - JavaScript | We are required to write a JavaScript function that takes in any number of JavaScript arrays and returns one single array with all the values from input arrays concatenated into it.
For example − If the input arrays are −
[1, 5], [44, 67, 3], [2, 5], [7], [4], [3, 7], [6]
Then the output should be −
const output = [1, ... | [
{
"code": null,
"e": 1244,
"s": 1062,
"text": "We are required to write a JavaScript function that takes in any number of JavaScript arrays and returns one single array with all the values from input arrays concatenated into it."
},
{
"code": null,
"e": 1284,
"s": 1244,
"text": "... |
Hiding SAP ABAP table control column | You can use the structure CXTAB_CONTROL that has the following components:
INVISIBLE C(1) Flag (X or blank) for visibility of entire table control.
You can use sample program: RSDEMO02 that allow you to modify properties of table control and view the results.
When you use this Table control INVISIBLE, this changes the ... | [
{
"code": null,
"e": 1137,
"s": 1062,
"text": "You can use the structure CXTAB_CONTROL that has the following components:"
},
{
"code": null,
"e": 1210,
"s": 1137,
"text": "INVISIBLE C(1) Flag (X or blank) for visibility of entire table control."
},
{
"code": null,
"e... |
Local Inner Class in C# | A nested class is a class declared in another enclosing class and it has inner as well as outer class. It is a member of its enclosing class and the members of an enclosing class have no access to members of a nested class
Let us see an example code snippet of nested classes in C#.
Here, class Two is a local inner clas... | [
{
"code": null,
"e": 1285,
"s": 1062,
"text": "A nested class is a class declared in another enclosing class and it has inner as well as outer class. It is a member of its enclosing class and the members of an enclosing class have no access to members of a nested class"
},
{
"code": null,
... |
Python program to validate email address | Suppose we have an email address as string. We have to check whether this is valid or not based on the following conditions −
The format must be username@company.domain format
The format must be username@company.domain format
Username can only contain upper and lowercase letters, numbers, dashes and underscores
Usernam... | [
{
"code": null,
"e": 1188,
"s": 1062,
"text": "Suppose we have an email address as string. We have to check whether this is valid or not based on the following conditions −"
},
{
"code": null,
"e": 1238,
"s": 1188,
"text": "The format must be username@company.domain format"
},
... |
Why do we need a copy constructor and when should we use a copy constructor in Java? | A copy constructor is a parameterized constructor and it can be used when we want to copy the values of one object to another.
class Employee {
int id;
String name;
Employee(int id, String name)
{
this.id = id;
this.name = name;
}
Employee(Employee e)
{
id = e.id;
name = e.... | [
{
"code": null,
"e": 1189,
"s": 1062,
"text": "A copy constructor is a parameterized constructor and it can be used when we want to copy the values of one object to another."
},
{
"code": null,
"e": 1636,
"s": 1189,
"text": "class Employee {\n int id;\n String name;\n\n Emp... |
Firebase - Google Authentication | In this chapter, we will show you how to set up Google authentication in Firebase.
Open Firebase dashboard and click Auth on the left side menu. To open the list of available methods, you need to click on SIGN_IN_METHODS in the tab menu.
Now you can choose Google from the list, enable it and save it.
Inside our index.h... | [
{
"code": null,
"e": 2249,
"s": 2166,
"text": "In this chapter, we will show you how to set up Google authentication in Firebase."
},
{
"code": null,
"e": 2404,
"s": 2249,
"text": "Open Firebase dashboard and click Auth on the left side menu. To open the list of available methods... |
Introducing Python’s Functools Module | by Amayo Mordecai II | Towards Data Science | The functools module, part of Python’s standard Library, provides useful features that make it easier to work with high order functions (a function that returns a function or takes another function as an argument ). With these features, you can reuse or extend the utility of your functions or callable object without re... | [
{
"code": null,
"e": 583,
"s": 172,
"text": "The functools module, part of Python’s standard Library, provides useful features that make it easier to work with high order functions (a function that returns a function or takes another function as an argument ). With these features, you can reuse or e... |
How to Deploy a Python Serverless Function to Vercel | by Mahbub Zaman | Towards Data Science | Vercel is a platform that provides serverless runtimes, also known as function as a service (FaaS). But why do I need to go serverless? Well, there are no straight forward answers if you need to go serverless or not. Generally, serverless functions are scalable with no maintenance. Moreover, you’re only running the fun... | [
{
"code": null,
"e": 517,
"s": 171,
"text": "Vercel is a platform that provides serverless runtimes, also known as function as a service (FaaS). But why do I need to go serverless? Well, there are no straight forward answers if you need to go serverless or not. Generally, serverless functions are sc... |
How to replace substring in MongoDB document? | In order to replace substring in MongoDB document, you can use the replace() function. To understand it further, let us create a collection with document. The query to create a collection with document is as follows −
> db.replaceSubstringDemo.insertOne({"WebsiteURL":"www.gogle.com"});
{
"acknowledged" : true,
"i... | [
{
"code": null,
"e": 1280,
"s": 1062,
"text": "In order to replace substring in MongoDB document, you can use the replace() function. To understand it further, let us create a collection with document. The query to create a collection with document is as follows −"
},
{
"code": null,
"e"... |
How to iterate the values in an enum in Java? | Enumeration (enum) in Java is a datatype which stores a set of constant values. You can use enumerations to store fixed values such as days in a week, months in a year etc.
enum Days {
SUNDAY, MONDAY, TUESDAY, WEDNESDAY, THURSDAY, FRIDAY, SATURDAY
}
You can iterate the contents of an enumeration using for loop, usin... | [
{
"code": null,
"e": 1235,
"s": 1062,
"text": "Enumeration (enum) in Java is a datatype which stores a set of constant values. You can use enumerations to store fixed values such as days in a week, months in a year etc."
},
{
"code": null,
"e": 1315,
"s": 1235,
"text": "enum Days... |
TypeORM - Creating a Simple Project | This chapter explains about how to create simple TypeORM application. Let us create a new directory named ‘TypeORM’ and move into the directory.
cd /path/to/TypeORM/
Use below command to create new project −
typeorm init --name <project-name> --database <database-name>
typeorm init --name FirstProject --database mysq... | [
{
"code": null,
"e": 2196,
"s": 2051,
"text": "This chapter explains about how to create simple TypeORM application. Let us create a new directory named ‘TypeORM’ and move into the directory."
},
{
"code": null,
"e": 2218,
"s": 2196,
"text": "cd /path/to/TypeORM/\n"
},
{
... |
Difference between while(1) and while(0) in C/C++ | Here we will see what are the differences between while(1) and while(0) in C or C++. The while is a loop of C or C++. Using this loop we can check one condition, and the statements inside the loop will be executed while the condition is true.
The while(1) or while(any non-zero value) is used for infinite loop. There is... | [
{
"code": null,
"e": 1305,
"s": 1062,
"text": "Here we will see what are the differences between while(1) and while(0) in C or C++. The while is a loop of C or C++. Using this loop we can check one condition, and the statements inside the loop will be executed while the condition is true."
},
{
... |
JavaScript String - toLowerCase() Method | This method returns the calling string value converted to lowercase.
Its syntax is as follows −
string.toLowerCase( )
Returns the calling string value converted to lowercase.
Try the following example.
<html>
<head>
<title>JavaScript String toLowerCase() Method</title>
</head>
<body>
<scrip... | [
{
"code": null,
"e": 2535,
"s": 2466,
"text": "This method returns the calling string value converted to lowercase."
},
{
"code": null,
"e": 2562,
"s": 2535,
"text": "Its syntax is as follows −"
},
{
"code": null,
"e": 2585,
"s": 2562,
"text": "string.toLowerC... |
Program for multiplication of array elements - GeeksforGeeks | 07 May, 2021
We are given an array, and we have to calculate the product of an array using both iterative and recursive methods.
Examples:
Input : array[] = {1, 2, 3, 4, 5, 6}
Output : 720
Here, product of elements = 1*2*3*4*5*6 = 720
Input : array[] = {1, 3, 5, 7, 9}
Output : 945
Iterative Method: We initialize r... | [
{
"code": null,
"e": 25310,
"s": 25282,
"text": "\n07 May, 2021"
},
{
"code": null,
"e": 25427,
"s": 25310,
"text": "We are given an array, and we have to calculate the product of an array using both iterative and recursive methods. "
},
{
"code": null,
"e": 25439,
... |
Configuring Face Unlock in Ubuntu | Howdy - GeeksforGeeks | 26 Aug, 2019
With the growth of AI and Machine Learning, the power of face recognition is increasing day by day. It has a lot of applications one of which is face authentication. So, to configure face unlock in ubuntu we will use howdy which provides Windows HelloTM style authentication for Linux. It is open-source, wr... | [
{
"code": null,
"e": 24566,
"s": 24538,
"text": "\n26 Aug, 2019"
},
{
"code": null,
"e": 24956,
"s": 24566,
"text": "With the growth of AI and Machine Learning, the power of face recognition is increasing day by day. It has a lot of applications one of which is face authenticatio... |
Gray Code | Practice | GeeksforGeeks | N = 2
Output:
00 01 11 10
Explanation:
00 and 01 differ by one bit.
01 and 11 differ by one bit.
11 and 10 also differ by one bit.
Input:
N=3
Output:
000 001 011 010 110 111 101 100
Explanation:
000 and 001 differ by one bit.
001 and 011 differ by one bit.
011 and 010 differ by one bit.
Similarly, every successive pa... | [
{
"code": null,
"e": 378,
"s": 238,
"text": "\nN = 2\nOutput: \n00 01 11 10\nExplanation: \n00 and 01 differ by one bit.\n01 and 11 differ by one bit.\n11 and 10 also differ by one bit."
},
{
"code": null,
"e": 592,
"s": 378,
"text": "Input:\nN=3\nOutput:\n000 001 011 010 110 111... |
Product of all the Composite Numbers in an array in C++ | Given an array arr[n] of n number of integers, the task is to find the product of all composite numbers in an array.
Composite numbers are the whole numbers which are made by multiplying 2 other whole numbers. For example 6 is a composite number which can be made by multiplying 2 and 3 which are whole numbers. Also we ... | [
{
"code": null,
"e": 1179,
"s": 1062,
"text": "Given an array arr[n] of n number of integers, the task is to find the product of all composite numbers in an array."
},
{
"code": null,
"e": 1410,
"s": 1179,
"text": "Composite numbers are the whole numbers which are made by multipl... |
Divide a DataFrame in a ratio - GeeksforGeeks | 17 Aug, 2020
Pandas is an open-source library that is built on top of numpy library. A Dataframe is a two-dimensional data structure, like data is aligned in a tabular fashion in rows and columns. DataFrame.sample() Method can be used to divide the Dataframe.
Syntax: DataFrame.sample(n=None, frac=None, replace=False, ... | [
{
"code": null,
"e": 24292,
"s": 24264,
"text": "\n17 Aug, 2020"
},
{
"code": null,
"e": 24540,
"s": 24292,
"text": "Pandas is an open-source library that is built on top of numpy library. A Dataframe is a two-dimensional data structure, like data is aligned in a tabular fashion ... |
Ridge, LASSO, and ElasticNet Regression | by James Andrew Godwin | Towards Data Science | This article is a continuation of last week’s intro to regularization with linear regression. Lettuce yonder back into the nitty-gritty of making the best data science/ machine learning models possible with more advanced techniques on simplifying our models. How do we simplify our models? By removing as many features a... | [
{
"code": null,
"e": 861,
"s": 171,
"text": "This article is a continuation of last week’s intro to regularization with linear regression. Lettuce yonder back into the nitty-gritty of making the best data science/ machine learning models possible with more advanced techniques on simplifying our mode... |
How to set the thumbnail image on video in HTML 5 ? | 27 Apr, 2020
Introduction: In this article, we are going to learn how to set a thumbnail image for an HTML5 video. Thumbnail is the image that is displayed as a preview of the video. Basically it is used to represent what the video contains or what it is related to. It is displayed until the time the video is started. ... | [
{
"code": null,
"e": 54,
"s": 26,
"text": "\n27 Apr, 2020"
},
{
"code": null,
"e": 453,
"s": 54,
"text": "Introduction: In this article, we are going to learn how to set a thumbnail image for an HTML5 video. Thumbnail is the image that is displayed as a preview of the video. Basi... |
Steady State Model using MATLAB | 20 Aug, 2020
A steady state model must be utilized to produce an underlying state when the model is begun from rest, an alleged “cold beginning.” On the off chance that a system is in a steady state, at that point the as of late watched conduct of the system will proceed into what’s to come. In systems, a system or a p... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n20 Aug, 2020"
},
{
"code": null,
"e": 487,
"s": 28,
"text": "A steady state model must be utilized to produce an underlying state when the model is begun from rest, an alleged “cold beginning.” On the off chance that a system is in a st... |
Java.io.InputStream Class in Java | 01 Mar, 2018
InputStream class is the superclass of all the io classes i.e. representing an input stream of bytes. It represents input stream of bytes. Applications that are defining subclass of InputStream must provide method, returning the next byte of input.A reset() method is invoked which re-positions the stream t... | [
{
"code": null,
"e": 52,
"s": 24,
"text": "\n01 Mar, 2018"
},
{
"code": null,
"e": 404,
"s": 52,
"text": "InputStream class is the superclass of all the io classes i.e. representing an input stream of bytes. It represents input stream of bytes. Applications that are defining subc... |
Remove unnecessary values from an Object in R Programming – na.omit() Function | 23 Jun, 2020
na.omit() function in R Language is used to omit all unnecessary cases from data frame, matrix or vector.
Syntax: na.omit(data)
Parameter:data: Set of specified values of data frame, matrix or vector.
Returns: Range of values after NA omission.
Example 1:
# R program to remove # unnecessary values # Creat... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n23 Jun, 2020"
},
{
"code": null,
"e": 134,
"s": 28,
"text": "na.omit() function in R Language is used to omit all unnecessary cases from data frame, matrix or vector."
},
{
"code": null,
"e": 156,
"s": 134,
"text": "... |
A Measure of Linear Relationship. Pearson’s product-moment correlation... | by Shinichi Okada | Towards Data Science | Table of ContentsIntroduction1. Import necessary libraries2. Finding the regression line3. Pearson’s correlation coefficient4. Finding Pearson’s correlation coefficient5. Degree of freedom and critical values6. The least-squares regression line7. The mean point on the line of best fit8. Real-life example9. Finding r fr... | [
{
"code": null,
"e": 538,
"s": 172,
"text": "Table of ContentsIntroduction1. Import necessary libraries2. Finding the regression line3. Pearson’s correlation coefficient4. Finding Pearson’s correlation coefficient5. Degree of freedom and critical values6. The least-squares regression line7. The mean... |
Tryit Editor v3.6 - Show Java | public class Main {
public static void main(String[] args) {
Person myObj = new Person();
myObj.setName("John");
System.out.println(myObj.getName());
}
}
public class Person {
private String name;
// Getter
public String getName() {
return name;
}
// Setter
public void setNam... | [
{
"code": null,
"e": 173,
"s": 0,
"text": "\npublic class Main {\n public static void main(String[] args) {\n Person myObj = new Person();\n myObj.setName(\"John\");\n System.out.println(myObj.getName());\n }\n}\n\n"
}
] |
Check if all array elements are distinct in Python | Suppose we have a list of numbers called nums, we have to check whether all elements in nums are unique or not.
So, if the input is like nums = [2, 3, 6, 5, 1, 8], then the output will be True as all elements are unique.
To solve this, we will follow these steps −
n := size of l
s := a new set
for i in range 0 to n, do... | [
{
"code": null,
"e": 1174,
"s": 1062,
"text": "Suppose we have a list of numbers called nums, we have to check whether all elements in nums are unique or not."
},
{
"code": null,
"e": 1283,
"s": 1174,
"text": "So, if the input is like nums = [2, 3, 6, 5, 1, 8], then the output wi... |
Android - Session Management | Session help you when want to store user data outside your application, so that when the next time user use your application, you can easily get back his details and perform accordingly.
This can be done in many ways. But the most easiest and nicest way of doing this is through Shared Preferences.
Shared Preferences al... | [
{
"code": null,
"e": 3794,
"s": 3607,
"text": "Session help you when want to store user data outside your application, so that when the next time user use your application, you can easily get back his details and perform accordingly."
},
{
"code": null,
"e": 3906,
"s": 3794,
"tex... |
Model with TensorFlow and Serve on Google Cloud Platform | by MA Raza, Ph.D. | Towards Data Science | In this guide, we learn how to develop a TensorFlow model and serve it on the Google Cloud Platform (GCP). We consider a regression problem of predicting the earnings of products using a three-layer neural network implemented with TensorFlow and Keras APIs.
The key learning outcomes of this guide are
Build, compile and... | [
{
"code": null,
"e": 429,
"s": 171,
"text": "In this guide, we learn how to develop a TensorFlow model and serve it on the Google Cloud Platform (GCP). We consider a regression problem of predicting the earnings of products using a three-layer neural network implemented with TensorFlow and Keras API... |
C# | Removing a range of elements from the List - GeeksforGeeks | 01 Feb, 2019
List<T>.RemoveRange(Int32, Int32) Method is used to remove a range of elements from the List<T>.
Properties of List:
It is different from the arrays. A list can be resized dynamically but arrays cannot.
List class can accept null as a valid value for reference types and it also allows duplicate elements.
I... | [
{
"code": null,
"e": 24222,
"s": 24194,
"text": "\n01 Feb, 2019"
},
{
"code": null,
"e": 24319,
"s": 24222,
"text": "List<T>.RemoveRange(Int32, Int32) Method is used to remove a range of elements from the List<T>."
},
{
"code": null,
"e": 24339,
"s": 24319,
"t... |
Puppeteer - Synchronization | Puppeteer Page class contains methods to achieve synchronization. These methods are used to wait for an action/element on the page. It waits for criteria to be met (a true value). For example, we often wait for a text to appear on the page.
The synchronization methods in Puppeteer are listed below −
This method is used... | [
{
"code": null,
"e": 2991,
"s": 2750,
"text": "Puppeteer Page class contains methods to achieve synchronization. These methods are used to wait for an action/element on the page. It waits for criteria to be met (a true value). For example, we often wait for a text to appear on the page."
},
{
... |
How to create a MySQL table with MyISAM engine table? | To create a MySQL table with MyISAM engine, we can use ENGINE command. Let us first create a table using CREATE command.
mysql> create table StudentRecordWithMyISAM
-> (
-> Id int,
-> StudentName varchar(100),
-> StudentAge int
-> )ENGINE=MyISAM;
Query OK, 0 rows affected (0.26 sec)
Above, we have set th... | [
{
"code": null,
"e": 1183,
"s": 1062,
"text": "To create a MySQL table with MyISAM engine, we can use ENGINE command. Let us first create a table using CREATE command."
},
{
"code": null,
"e": 1361,
"s": 1183,
"text": "mysql> create table StudentRecordWithMyISAM\n -> (\n -> I... |
HTML - <span> Tag | The HTML <span> tag is used for grouping and applying styles to inline elements.
There is a difference between the span tag and the div tag. The span tag is used with inline elements whilst the div tag is used with block-level content.
<!DOCTYPE html>
<html>
<head>
<title>HTML span Tag</title>
</head>
... | [
{
"code": null,
"e": 2455,
"s": 2374,
"text": "The HTML <span> tag is used for grouping and applying styles to inline elements."
},
{
"code": null,
"e": 2610,
"s": 2455,
"text": "There is a difference between the span tag and the div tag. The span tag is used with inline elements... |
Combine columns into rows with MySQL? | To combine columns into rows, use UNION ALL. Following is the syntax −
select yourColumnName1 from yourTableName
union all
select yourColumnName2 from yourTableName;
Let us first create a table −
mysql> create table DemoTable
-> (
-> Value1 int,
-> Value2 int
-> );
Query OK, 0 rows affected (0.88 sec)
In... | [
{
"code": null,
"e": 1133,
"s": 1062,
"text": "To combine columns into rows, use UNION ALL. Following is the syntax −"
},
{
"code": null,
"e": 1231,
"s": 1133,
"text": "select yourColumnName1 from yourTableName\n union all\nselect yourColumnName2 from yourTableName;"
},
{
... |
Parsing XML, Named Entity Recognition in One-Shot | by Susan Li | Towards Data Science | Parsing XML is a process that is designed to read XML and create a way for programs to use XML. An XML parser is the piece of software that reads XML files and makes the information from those files available to applications.
While reading an XML file, a parser checks the syntax for the format, and reports any violatio... | [
{
"code": null,
"e": 398,
"s": 172,
"text": "Parsing XML is a process that is designed to read XML and create a way for programs to use XML. An XML parser is the piece of software that reads XML files and makes the information from those files available to applications."
},
{
"code": null,
... |
How to make the marker face color transparent without making the line transparent in Matplotlib? | To make the marker face color transparent without making the line transparent in matplotlib, we can take the following steps −
Create x_data and y_data(sin(x_data)), using numpy.
Create x_data and y_data(sin(x_data)), using numpy.
Plot curve using x_data and y_data, with marker style and marker size. By changing the al... | [
{
"code": null,
"e": 1189,
"s": 1062,
"text": "To make the marker face color transparent without making the line transparent in matplotlib, we can take the following steps −"
},
{
"code": null,
"e": 1241,
"s": 1189,
"text": "Create x_data and y_data(sin(x_data)), using numpy."
... |
Program to check robot can reach target position or not in Python | Suppose we have a robot, that is currently sitting in at position (0, 0) (Cartesian plane). If we
have list of its moves that it can make, containing N(North), S(South), W(West), and E(East). We
have to check whether it can reach at destination coordinate (x, y).
So, if the input is like moves = ['N','N','E','E','S'], ... | [
{
"code": null,
"e": 1326,
"s": 1062,
"text": "Suppose we have a robot, that is currently sitting in at position (0, 0) (Cartesian plane). If we\nhave list of its moves that it can make, containing N(North), S(South), W(West), and E(East). We\nhave to check whether it can reach at destination coordi... |
Cassandra - Batch Statements | Using BATCH, you can execute multiple modification statements (insert, update, delete) simultaneiously. Its syntax is as follows −
BEGIN BATCH
<insert-stmt>/ <update-stmt>/ <delete-stmt>
APPLY BATCH
Assume there is a table in Cassandra called emp having the following data −
In this example, we will perform the followi... | [
{
"code": null,
"e": 2418,
"s": 2287,
"text": "Using BATCH, you can execute multiple modification statements (insert, update, delete) simultaneiously. Its syntax is as follows −"
},
{
"code": null,
"e": 2487,
"s": 2418,
"text": "BEGIN BATCH\n<insert-stmt>/ <update-stmt>/ <delete-... |
Octal Arithmetic | Following are the characteristics of an octal number system.
Uses eight digits, 0,1,2,3,4,5,6,7.
Uses eight digits, 0,1,2,3,4,5,6,7.
Also called base 8 number system.
Also called base 8 number system.
Each position in an octal number represents a 0 power of the base (8). Example: 80
Each position in an octal number rep... | [
{
"code": null,
"e": 2032,
"s": 1971,
"text": "Following are the characteristics of an octal number system."
},
{
"code": null,
"e": 2068,
"s": 2032,
"text": "Uses eight digits, 0,1,2,3,4,5,6,7."
},
{
"code": null,
"e": 2104,
"s": 2068,
"text": "Uses eight dig... |
PHP - File Inclusion | You can include the content of a PHP file into another PHP file before the server executes it. There are two PHP functions which can be used to included one PHP file into another PHP file.
The include() Function
The require() Function
This is a strong point of PHP which helps in creating functions, headers, footers, or... | [
{
"code": null,
"e": 2946,
"s": 2757,
"text": "You can include the content of a PHP file into another PHP file before the server executes it. There are two PHP functions which can be used to included one PHP file into another PHP file."
},
{
"code": null,
"e": 2969,
"s": 2946,
"t... |
ES6 - Boolean | The Boolean object represents two values, either "true" or "false". If the value parameter is omitted or is 0, -0, null, false, NaN, undefined, or the empty string (""), the object has an initial value of false.
Use the following syntax to create a boolean object.
var val = new Boolean(value);
Following is a list of t... | [
{
"code": null,
"e": 2489,
"s": 2277,
"text": "The Boolean object represents two values, either \"true\" or \"false\". If the value parameter is omitted or is 0, -0, null, false, NaN, undefined, or the empty string (\"\"), the object has an initial value of false."
},
{
"code": null,
"e"... |
C++ Arithmetic Operators | Try the following example to understand all the arithmetic operators available in C++.
Copy and paste the following C++ program in test.cpp file and compile and run this program.
#include <iostream>
using namespace std;
main() {
int a = 21;
int b = 10;
int c ;
c = a + b;
cout << "Line 1 - Value of c ... | [
{
"code": null,
"e": 2405,
"s": 2318,
"text": "Try the following example to understand all the arithmetic operators available in C++."
},
{
"code": null,
"e": 2497,
"s": 2405,
"text": "Copy and paste the following C++ program in test.cpp file and compile and run this program."
... |
Python Arithmetic Operators Example | Assume variable a holds 10 and variable b holds 20, then −
Assume variable a holds 21 and variable b holds 10, then −
#!/usr/bin/python
a = 21
b = 10
c = 0
c = a + b
print "Line 1 - Value of c is ", c
c = a - b
print "Line 2 - Value of c is ", c
c = a * b
print "Line 3 - Value of c is ", c
c = a / b
print "Line ... | [
{
"code": null,
"e": 2303,
"s": 2244,
"text": "Assume variable a holds 10 and variable b holds 20, then −"
},
{
"code": null,
"e": 2362,
"s": 2303,
"text": "Assume variable a holds 21 and variable b holds 10, then −"
},
{
"code": null,
"e": 2751,
"s": 2362,
"t... |
Data Scientist vs Business Intelligence Analyst. Here’s the Difference. | Towards Data Science | IntroductionData ScientistBusiness Intelligence AnalystDifferencesSimilaritiesSummaryReferences
Introduction
Data Scientist
Business Intelligence Analyst
Differences
Similarities
Summary
References
I have compared several other similar jobs to Data Science in past articles, and now will be comparing the role of Busines... | [
{
"code": null,
"e": 268,
"s": 172,
"text": "IntroductionData ScientistBusiness Intelligence AnalystDifferencesSimilaritiesSummaryReferences"
},
{
"code": null,
"e": 281,
"s": 268,
"text": "Introduction"
},
{
"code": null,
"e": 296,
"s": 281,
"text": "Data Sci... |
CONCATENATE in Excel - GeeksforGeeks | 01 Jun, 2021
Excel provides us the flexibility to combine the data from two or more columns into singular column data. For example: Joining the First Name, Middle Name, and Last Name of a person into a single column Full Name. There are two ways in which we can concatenate two or more cell data or texts :
Using the key... | [
{
"code": null,
"e": 25070,
"s": 25042,
"text": "\n01 Jun, 2021"
},
{
"code": null,
"e": 25364,
"s": 25070,
"text": "Excel provides us the flexibility to combine the data from two or more columns into singular column data. For example: Joining the First Name, Middle Name, and Las... |
Java Concurrency - ReadWriteLock Interface | A java.util.concurrent.locks.ReadWriteLock interface allows multiple threads to read at a time but only one thread can write at a time.
Read Lock − If no thread has locked the ReadWriteLock for writing then multiple thread can access the read lock.
Read Lock − If no thread has locked the ReadWriteLock for writing the... | [
{
"code": null,
"e": 2795,
"s": 2657,
"text": "A java.util.concurrent.locks.ReadWriteLock interface allows multiple threads to read at a time but only one thread can write at a time. \n"
},
{
"code": null,
"e": 2908,
"s": 2795,
"text": "Read Lock − If no thread has locked the Rea... |
Unzip, update and zip again XMLs in a folder | by Vaclav Dekanovsky | Towards Data Science | In daily office work, you often have to do something with a bunch of files. Unzip, move, rename, update, zip again, and send or load to FTP. All of these things are simple to do, but very time-consuming of you have to repeat them manually on the tens or hundreds of files.
Luckily you can use programming languages to au... | [
{
"code": null,
"e": 444,
"s": 171,
"text": "In daily office work, you often have to do something with a bunch of files. Unzip, move, rename, update, zip again, and send or load to FTP. All of these things are simple to do, but very time-consuming of you have to repeat them manually on the tens or h... |
How to change the marker size with pandas.plot() in Matplotlib? | To change the marker size with pandas.plot(), we can take the following steps −
Set the figure size and adjust the padding between and around the subplots.
Create a Pandas dataframe with three columns, col1, col2 and col3.
Use pandas.plot() with marker="*" and markersize=15.
To display the figure, use show() method.
im... | [
{
"code": null,
"e": 1142,
"s": 1062,
"text": "To change the marker size with pandas.plot(), we can take the following steps −"
},
{
"code": null,
"e": 1218,
"s": 1142,
"text": "Set the figure size and adjust the padding between and around the subplots."
},
{
"code": null... |
Bottom View of Binary Tree | Practice | GeeksforGeeks | Given a binary tree, print the bottom view from left to right.
A node is included in bottom view if it can be seen when we look at the tree from bottom.
20
/ \
8 22
/ \ \
5 3 25
/ ... | [
{
"code": null,
"e": 391,
"s": 238,
"text": "Given a binary tree, print the bottom view from left to right.\nA node is included in bottom view if it can be seen when we look at the tree from bottom."
},
{
"code": null,
"e": 594,
"s": 391,
"text": " 20\n ... |
C++ Program For Converting Roman Numerals To Decimal Lying Between 1 to 3999 - GeeksforGeeks | 03 Jan, 2022
Given a Romal numeral, the task is to find its corresponding decimal value.
Example :
Input: IX
Output: 9
IX is a Roman symbol which represents 9
Input: XL
Output: 40
XL is a Roman symbol which represents 40
Input: MCMIV
Output: 1904
M is a thousand,
CM is nine hundred and
IV is four
Roman numerals a... | [
{
"code": null,
"e": 24676,
"s": 24648,
"text": "\n03 Jan, 2022"
},
{
"code": null,
"e": 24752,
"s": 24676,
"text": "Given a Romal numeral, the task is to find its corresponding decimal value."
},
{
"code": null,
"e": 24763,
"s": 24752,
"text": "Example : "
... |
Argument Parsing in Python | Every programming language has a feature to create scripts and run them from the terminal or being called by other programs. When running such scripts we often need to pass on arguments needed by the script for various functions to be executed inside the script. In this article we will see what are the various ways to ... | [
{
"code": null,
"e": 1419,
"s": 1062,
"text": "Every programming language has a feature to create scripts and run them from the terminal or being called by other programs. When running such scripts we often need to pass on arguments needed by the script for various functions to be executed inside th... |
Apache HttpClient - Proxy Authentication | In this chapter, we will learn how to create a HttpRequest authenticated using username and password and tunnel it through a proxy to a target host, using an example.
The CredentialsProvider Interface maintains a collection to hold the user login credentials. You can create its object by instantiating the BasicCredenti... | [
{
"code": null,
"e": 1994,
"s": 1827,
"text": "In this chapter, we will learn how to create a HttpRequest authenticated using username and password and tunnel it through a proxy to a target host, using an example."
},
{
"code": null,
"e": 2212,
"s": 1994,
"text": "The Credentials... |
How to order by timestamp (descending order) in MongoDB | To order by timestamp, use sort() in MongoDB. Let us create a collection with documents −
> db.demo737.insertOne({"timestamp" : new ISODate("2020-04-01" )});
{
"acknowledged" : true,
"insertedId" : ObjectId("5ead682157bb72a10bcf065c")
}
> db.demo737.insertOne({"timestamp" : new ISODate("2020-10-31" )});
{
"ack... | [
{
"code": null,
"e": 1152,
"s": 1062,
"text": "To order by timestamp, use sort() in MongoDB. Let us create a collection with documents −"
},
{
"code": null,
"e": 1611,
"s": 1152,
"text": "> db.demo737.insertOne({\"timestamp\" : new ISODate(\"2020-04-01\" )});\n{\n \"acknowledge... |
Explain malloc function in C programming | Write a C program to display and add the elements using dynamic memory allocation functions.
In C, the library function malloc allocates a block of memory in bytes at runtime. It returns a void pointer, which points to the base address of allocated memory and it leaves the memory uninitialized.
void *malloc (size in by... | [
{
"code": null,
"e": 1155,
"s": 1062,
"text": "Write a C program to display and add the elements using dynamic memory allocation functions."
},
{
"code": null,
"e": 1358,
"s": 1155,
"text": "In C, the library function malloc allocates a block of memory in bytes at runtime. It ret... |
Python | Remove all occurrences in nested list | 16 May, 2019
The task of removal of element generally doesn’t pose any challenge, but sometimes, we may have a more complex problem than just removing a single element or performing removal in just a normal list. Problem can be removing all occurrences of nested list. Let’s discuss certain ways in which this problem ca... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n16 May, 2019"
},
{
"code": null,
"e": 348,
"s": 28,
"text": "The task of removal of element generally doesn’t pose any challenge, but sometimes, we may have a more complex problem than just removing a single element or performing remova... |
How to Convert SVG, PSD Images to Vector Drawable File in Android Studio? | 18 Feb, 2021
In order to use the SVG (Scalable Vector Graphics) or PSD (Photoshop document) image file in your android studio project, you have to first convert them into an XML (Vector Drawable) file. Why XML (Vector Drawable) file?
small in size
scalability (It scaled without loss of display quality)
height and width... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n18 Feb, 2021"
},
{
"code": null,
"e": 249,
"s": 28,
"text": "In order to use the SVG (Scalable Vector Graphics) or PSD (Photoshop document) image file in your android studio project, you have to first convert them into an XML (Vector Dr... |
Multiple Inheritance in C++ | 12 Jun, 2022
Multiple Inheritance is a feature of C++ where a class can inherit from more than one classes. The constructors of inherited classes are called in the same order in which they are inherited. For example, in the following program, B’s constructor is called before A’s constructor.
A class can be derived fro... | [
{
"code": null,
"e": 54,
"s": 26,
"text": "\n12 Jun, 2022"
},
{
"code": null,
"e": 335,
"s": 54,
"text": "Multiple Inheritance is a feature of C++ where a class can inherit from more than one classes. The constructors of inherited classes are called in the same order in which th... |
HTML | DOM onscroll Event | 27 Jul, 2021
The HTML DOM onscroll event occurs when a scrollbar is used. CSS overflow is used to create a scrollbar.Supported tags
<address>
, <blockquote>
, <body>
, <caption>
, <center>
, <dd>
, <dir>
, <div>
, <dl>
, <dt>
, <fieldset>
, <form>
, <h1>to <h6>
, <html>
, <li>
, <menu>
, <object>
, <ol>
, <p>
, <pre>
,... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n27 Jul, 2021"
},
{
"code": null,
"e": 147,
"s": 28,
"text": "The HTML DOM onscroll event occurs when a scrollbar is used. CSS overflow is used to create a scrollbar.Supported tags"
},
{
"code": null,
"e": 157,
"s": 147,
... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.