title stringlengths 3 221 | text stringlengths 17 477k | parsed listlengths 0 3.17k |
|---|---|---|
Building an Artificial Neural Network in One Line of Code | by Kasper Müller | Towards Data Science | There are tons of great theoretical articles out there on the anatomy and mathematics of artificial neural networks, so I am going to take another approach to writing about and teaching this subject. In this article, we are going to get our hands dirty right away!
Let’s jump right in. You can choose a section below if ... | [
{
"code": null,
"e": 436,
"s": 171,
"text": "There are tons of great theoretical articles out there on the anatomy and mathematics of artificial neural networks, so I am going to take another approach to writing about and teaching this subject. In this article, we are going to get our hands dirty ri... |
Automating Snippets in Visual Studio Code with Python | by Lucas Soares | Towards Data Science | Every good development workflow involves some kind of management of code snippets, where you are constantly storing and retrieving snippets of code to solve a wide range of tasks in your programming routine.
In this article, I will show you how to automate the process of creating snippets for VScode using Python to sav... | [
{
"code": null,
"e": 374,
"s": 166,
"text": "Every good development workflow involves some kind of management of code snippets, where you are constantly storing and retrieving snippets of code to solve a wide range of tasks in your programming routine."
},
{
"code": null,
"e": 554,
"... |
What is Data Cleaning? How to Process Data for Analytics and Machine Learning Modeling? | by Awan-Ur-Rahman | Towards Data Science | Data Cleaning plays an important role in the field of Data Managements as well as Analytics and Machine Learning. In this article, I will try to give the intuitions about the importance of data cleaning and different data cleaning processes.
Data Cleaning means the process of identifying the incorrect, incomplete, inac... | [
{
"code": null,
"e": 414,
"s": 172,
"text": "Data Cleaning plays an important role in the field of Data Managements as well as Analytics and Machine Learning. In this article, I will try to give the intuitions about the importance of data cleaning and different data cleaning processes."
},
{
... |
Difference between new and malloc( ) | In this post, we will understand the difference between ‘new’ and ‘malloc’.
It is present in C++, Java, and C#.
It is present in C++, Java, and C#.
It is an operator that can be used to call the constructor of the object.
It is an operator that can be used to call the constructor of the object.
It can be overloaded.
It... | [
{
"code": null,
"e": 1138,
"s": 1062,
"text": "In this post, we will understand the difference between ‘new’ and ‘malloc’."
},
{
"code": null,
"e": 1174,
"s": 1138,
"text": "It is present in C++, Java, and C#."
},
{
"code": null,
"e": 1210,
"s": 1174,
"text": ... |
Internet Technologies - Quick Reference Guide | Internet is a world-wide global system of interconnected computer networks.
Internet is a world-wide global system of interconnected computer networks.
Internet uses the standard Internet Protocol (TCP/IP).
Internet uses the standard Internet Protocol (TCP/IP).
Every computer in internet is identified by a unique IP ad... | [
{
"code": null,
"e": 2549,
"s": 2473,
"text": "Internet is a world-wide global system of interconnected computer networks."
},
{
"code": null,
"e": 2625,
"s": 2549,
"text": "Internet is a world-wide global system of interconnected computer networks."
},
{
"code": null,
... |
Differential Privacy in Deep Learning | by Neeraj Rajkumar Parmaar | Towards Data Science | I would like to thank Mr. Akshay Kulkarni for guiding me on my journey in publishing my first-ever article.
As a large number of our day to day activities are being moved online the amount of personal and sensitive data being recorded is also on the rise. This surge in data has also led to the increased data analysis t... | [
{
"code": null,
"e": 280,
"s": 172,
"text": "I would like to thank Mr. Akshay Kulkarni for guiding me on my journey in publishing my first-ever article."
},
{
"code": null,
"e": 778,
"s": 280,
"text": "As a large number of our day to day activities are being moved online the amou... |
C++ iomanip Library - setw Function | The C++ function std::setw behaves as if member width were called with n as argument on the stream on which it is inserted/extracted as a manipulator (it can be inserted/extracted on input streams or output streams).
It is used to sets the field width to be used on output operations.
Following is the declaration for s... | [
{
"code": null,
"e": 2821,
"s": 2603,
"text": "The C++ function std::setw behaves as if member width were called with n as argument on the stream on which it is inserted/extracted as a manipulator (it can be inserted/extracted on input streams or output streams)."
},
{
"code": null,
"e"... |
Setting up Python platform for Machine Learning projects | by Aqeel Anwar | Towards Data Science | There are a lot of in-depth tutorials on how to get started with machine learning using python. These tutorials mainly focus on the use of Deep Learning frameworks (say TensorFlow, PyTorch, Keras, etc.) such as how to set up basic supervised learning problem, or how to create a simple neural network and train it, etc. ... | [
{
"code": null,
"e": 665,
"s": 172,
"text": "There are a lot of in-depth tutorials on how to get started with machine learning using python. These tutorials mainly focus on the use of Deep Learning frameworks (say TensorFlow, PyTorch, Keras, etc.) such as how to set up basic supervised learning prob... |
Principal Component Analysis (PCA) from scratch in Python | by Dario Radečić | Towards Data Science | Principal Component Analysis is a mathematical technique used for dimensionality reduction. Its goal is to reduce the number of features whilst keeping most of the original information. Today we’ll implement it from scratch, using pure Numpy.
If you’re wondering why PCA is useful for your average machine learning task,... | [
{
"code": null,
"e": 415,
"s": 172,
"text": "Principal Component Analysis is a mathematical technique used for dimensionality reduction. Its goal is to reduce the number of features whilst keeping most of the original information. Today we’ll implement it from scratch, using pure Numpy."
},
{
... |
Install PostgreSQL on Linux - GeeksforGeeks | 24 Sep, 2021
This is a step-by-step guide to install PostgreSQL on a Linux machine. By default, PostgreSQL is available in all Ubuntu versions as PostgreSql “Snapshot”. However other versions of the same can be downloaded through the PostgreSQL apt repository.
We will be installing PostgreSQL version 11.3 on Ubuntu in... | [
{
"code": null,
"e": 23747,
"s": 23719,
"text": "\n24 Sep, 2021"
},
{
"code": null,
"e": 23996,
"s": 23747,
"text": "This is a step-by-step guide to install PostgreSQL on a Linux machine. By default, PostgreSQL is available in all Ubuntu versions as PostgreSql “Snapshot”. However... |
Scala - Access Modifiers | This chapter takes you through the Scala access modifiers. Members of packages, classes or objects can be labeled with the access modifiers private and protected, and if we are not using either of these two keywords, then access will be assumed as public. These modifiers restrict accesses to the members to certain regi... | [
{
"code": null,
"e": 2480,
"s": 1998,
"text": "This chapter takes you through the Scala access modifiers. Members of packages, classes or objects can be labeled with the access modifiers private and protected, and if we are not using either of these two keywords, then access will be assumed as publi... |
OpenCV - Median Blur | The Median blur operation is similar to the other averaging methods. Here, the central element of the image is replaced by the median of all the pixels in the kernel area. This operation processes the edges while removing the noise.
You can perform this operation on an image using the medianBlur() method of the imgproc... | [
{
"code": null,
"e": 3237,
"s": 3004,
"text": "The Median blur operation is similar to the other averaging methods. Here, the central element of the image is replaced by the median of all the pixels in the kernel area. This operation processes the edges while removing the noise."
},
{
"code"... |
Move columns to the right with Bootstrap | To move columns to the right, use the .col-*-offset-* class in Bootstrap.
You can try to run the following code to implement it
Live Demo
<!DOCTYPE html>
<html lang = "en">
<head>
<title>Bootstrap Example</title>
<meta charset = "utf-8">
<meta name = "viewport" content = "width=device-width, initia... | [
{
"code": null,
"e": 1136,
"s": 1062,
"text": "To move columns to the right, use the .col-*-offset-* class in Bootstrap."
},
{
"code": null,
"e": 1190,
"s": 1136,
"text": "You can try to run the following code to implement it"
},
{
"code": null,
"e": 1200,
"s": 11... |
Nagios - Add-ons/Plugins | Plugins helps to monitor databases, operating systems, applications, network equipment, protocols with Nagios. Plugins are compiled executables or script (Perl or non-Perl) that extends Nagios functionality to monitor servers and hosts. Nagios will execute a Plugin to check the status of a service or host. Nagios can b... | [
{
"code": null,
"e": 2413,
"s": 1896,
"text": "Plugins helps to monitor databases, operating systems, applications, network equipment, protocols with Nagios. Plugins are compiled executables or script (Perl or non-Perl) that extends Nagios functionality to monitor servers and hosts. Nagios will exec... |
Complete Data Science Project Template with Mlflow for Non-Dummies. | by Jan Teichmann | Towards Data Science | Data science has come a long way as a field and business function alike. There are now cross-functional teams working on algorithms all the way to full-stack data science products.
With the growing maturity of data science there is an emerging standard of best practise, platforms and toolkits which significantly reduce... | [
{
"code": null,
"e": 353,
"s": 172,
"text": "Data science has come a long way as a field and business function alike. There are now cross-functional teams working on algorithms all the way to full-stack data science products."
},
{
"code": null,
"e": 790,
"s": 353,
"text": "With ... |
How do I manually throw/raise an exception in Python? | We use the most specific exception constructor that fits our specific issue rather than raise generic exceptions. To catch our specific exception, we'll have to catch all other more specific exceptions that subclass it.
We should raise specific exceptions and handle the same specific exceptions.
To raise the specific e... | [
{
"code": null,
"e": 1282,
"s": 1062,
"text": "We use the most specific exception constructor that fits our specific issue rather than raise generic exceptions. To catch our specific exception, we'll have to catch all other more specific exceptions that subclass it."
},
{
"code": null,
"... |
Get all subdirectories of a given directory in PHP | To get the subdirectories present in a directory, the below lines of code can be used −
Live Demo
<?php
$all_sub_dirs = array_filter(glob('*.*'), 'is_dir');
print_r($all_sub_dirs);
?>
This will produce the following output. The glob function is used to get all the subdirectories of a specific directory−
Array (
... | [
{
"code": null,
"e": 1150,
"s": 1062,
"text": "To get the subdirectories present in a directory, the below lines of code can be used −"
},
{
"code": null,
"e": 1161,
"s": 1150,
"text": " Live Demo"
},
{
"code": null,
"e": 1253,
"s": 1161,
"text": "<?php\n $a... |
Deploy MLflow with docker compose | by Guillaume Androz | Towards Data Science | When in the process of building and training machine learning models, its very important to keep track of the results of each experiment. For deep learning models, TensorBoard is a very power tool to log training performances, track gradient, debug a model and so on. We also need to track the associated source code, an... | [
{
"code": null,
"e": 845,
"s": 172,
"text": "When in the process of building and training machine learning models, its very important to keep track of the results of each experiment. For deep learning models, TensorBoard is a very power tool to log training performances, track gradient, debug a mode... |
Sklearn pipeline tutorial | Towards Data Science | Most of the data science projects (as keen as I am to say all of them) require a certain level of data cleaning and preprocessing to make the most of the machine learning models. Some common preprocessing or transformations are:
a. Imputing missing values
b. Removing outliers
c. Normalising or standardising numerical f... | [
{
"code": null,
"e": 400,
"s": 171,
"text": "Most of the data science projects (as keen as I am to say all of them) require a certain level of data cleaning and preprocessing to make the most of the machine learning models. Some common preprocessing or transformations are:"
},
{
"code": null... |
Add Index ID to DataFrame in R - GeeksforGeeks | 13 Aug, 2021
In this article, we will discuss how index ID can be added to dataframes in the R programming language.
The nrow() method in R Programming language is used to compute the number of rows in the dataframe that is specified as an argument of this method. cbind() method in R language is used to append a vector... | [
{
"code": null,
"e": 25162,
"s": 25134,
"text": "\n13 Aug, 2021"
},
{
"code": null,
"e": 25266,
"s": 25162,
"text": "In this article, we will discuss how index ID can be added to dataframes in the R programming language."
},
{
"code": null,
"e": 25678,
"s": 25266,... |
Dart Programming - while Loop | The while loop executes the instructions each time the condition specified evaluates to true. In other words, the loop evaluates the condition before the block of code is executed.
The following illustration shows the flowchart of the while loop −
Following is the syntax for the while loop.
while (expression) {
Sta... | [
{
"code": null,
"e": 2706,
"s": 2525,
"text": "The while loop executes the instructions each time the condition specified evaluates to true. In other words, the loop evaluates the condition before the block of code is executed."
},
{
"code": null,
"e": 2773,
"s": 2706,
"text": "T... |
How to create table rows & columns in HTML? | To create table rows and columns in HTML, use the <table> tag. A table consist of rows and columns, which can be set using one or more <tr>, <th>, and <td> elements. A table row is defined by the <tr> tag. For table rows and columns, <tr> tag and <td> tag is used respectively. The <td> tag
Just keep in mind, a lot of t... | [
{
"code": null,
"e": 1353,
"s": 1062,
"text": "To create table rows and columns in HTML, use the <table> tag. A table consist of rows and columns, which can be set using one or more <tr>, <th>, and <td> elements. A table row is defined by the <tr> tag. For table rows and columns, <tr> tag and <td> t... |
How to parse HTML in Android using Kotlin? | This example demonstrates how to parse HTML 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"?>
<RelativeLayout xm... | [
{
"code": null,
"e": 1131,
"s": 1062,
"text": "This example demonstrates how to parse HTML in Android using Kotlin."
},
{
"code": null,
"e": 1260,
"s": 1131,
"text": "Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required details to create... |
SkipWhile method in C# | SkipWhile skips an element when a condition is matched.
For example, use the following if you want to skip all even elements −
ele => ele %2 == 0
The following is an example wherein all the even elements are skipped and only the odd elements are displayed −
Live Demo
using System.IO;
using System;
using System.Linq;
p... | [
{
"code": null,
"e": 1118,
"s": 1062,
"text": "SkipWhile skips an element when a condition is matched."
},
{
"code": null,
"e": 1189,
"s": 1118,
"text": "For example, use the following if you want to skip all even elements −"
},
{
"code": null,
"e": 1208,
"s": 118... |
Java Connection getMetaData() method with example | Generally, Data about data is known as metadata. The DatabaseMetaData interface provides methods to get information about the database you have connected with like, database name, database driver version, maximum column length etc...
The getMetaData() method of the Connection interface retrieves and returns the Databas... | [
{
"code": null,
"e": 1296,
"s": 1062,
"text": "Generally, Data about data is known as metadata. The DatabaseMetaData interface provides methods to get information about the database you have connected with like, database name, database driver version, maximum column length etc..."
},
{
"code... |
Flutter - Liquid Swipe Animation - GeeksforGeeks | 15 Jan, 2021
Liquid Swipe animation is used to slide the page like water which show different design and pattern on the screen. It creates a floating state. Liquid Swipe animation is a significantly trending design procedure. Movement can help keep clients inspired by your UI design longer and more motivated to collabo... | [
{
"code": null,
"e": 23930,
"s": 23902,
"text": "\n15 Jan, 2021"
},
{
"code": null,
"e": 24319,
"s": 23930,
"text": "Liquid Swipe animation is used to slide the page like water which show different design and pattern on the screen. It creates a floating state. Liquid Swipe animat... |
How to move or position a legend in ggplot2? - GeeksforGeeks | 06 Jun, 2021
In this article, we will discuss how to control a legend position in ggplot using an R programming language. To draw a legend within ggplot the parameter col is used, it basically adds colors to the plot and these colors are used to differentiate between different plots. To depict what each color represent... | [
{
"code": null,
"e": 26487,
"s": 26459,
"text": "\n06 Jun, 2021"
},
{
"code": null,
"e": 26872,
"s": 26487,
"text": "In this article, we will discuss how to control a legend position in ggplot using an R programming language. To draw a legend within ggplot the parameter col is us... |
Kotlin functions - GeeksforGeeks | 28 Mar, 2022
A function is a unit of code that performs a special task. In programming, function is used to break the code into smaller modules which makes the program more manageable. For example: If we have to compute sum of two numbers then define a fun sum().
fun sum(a: Int, b: Int): Int {
return a + b
}
We can... | [
{
"code": null,
"e": 25523,
"s": 25495,
"text": "\n28 Mar, 2022"
},
{
"code": null,
"e": 25774,
"s": 25523,
"text": "A function is a unit of code that performs a special task. In programming, function is used to break the code into smaller modules which makes the program more man... |
GATE | GATE-CS-2005 | Question 85 - GeeksforGeeks | 12 Jul, 2021
Consider the following expression grammar. The semantic rules for expression calculation are stated next to each grammar production.
E → number E.val = number. val
| E '+' E E(1).val = E(2).val + E(3).val
| E '×' E E(1).val = E(2).val × E(3).val
The above grammar and the semantic rules are f... | [
{
"code": null,
"e": 25755,
"s": 25727,
"text": "\n12 Jul, 2021"
},
{
"code": null,
"e": 25889,
"s": 25755,
"text": "Consider the following expression grammar. The semantic rules for expression calculation are stated next to each grammar production."
},
{
"code": null,
... |
Find the count of distinct numbers in a range - GeeksforGeeks | 07 Sep, 2021
Given an array of size N containing numbers only from 0 to 63, and you are asked Q queries regarding it.Queries are as follows:
1 X Y i.e Change the element at index X to Y
2 L R i.e Print the count of distinct elements present in between L and R inclusive
Examples:
Input:
N = 7
ar = {1, 2, 1, 3, 1, 2,... | [
{
"code": null,
"e": 25975,
"s": 25947,
"text": "\n07 Sep, 2021"
},
{
"code": null,
"e": 26105,
"s": 25975,
"text": "Given an array of size N containing numbers only from 0 to 63, and you are asked Q queries regarding it.Queries are as follows: "
},
{
"code": null,
"... |
How do I create a date picker in tkinter? | Tkcalendar is a Python package which provides DateEntry and Calendar widgets for tkinter applications. In this article, we will create a date picker with the help of DateEntry Widget.
A DateEntry widget contains three fields that refer to the general format of Date as MM/DD/YY. By creating an object of DateEntry widget... | [
{
"code": null,
"e": 1246,
"s": 1062,
"text": "Tkcalendar is a Python package which provides DateEntry and Calendar widgets for tkinter applications. In this article, we will create a date picker with the help of DateEntry Widget."
},
{
"code": null,
"e": 1434,
"s": 1246,
"text":... |
Find path to the given file using Python - GeeksforGeeks | 13 Jan, 2021
We can get the location (path) of the running script file .py with __file__. __file__ is useful for reading other files and it gives the current location of the running file. It differs in versions. In Python 3.8 and earlier, __file__ returns the path specified when executing the python (or python3) comman... | [
{
"code": null,
"e": 25691,
"s": 25663,
"text": "\n13 Jan, 2021"
},
{
"code": null,
"e": 26239,
"s": 25691,
"text": "We can get the location (path) of the running script file .py with __file__. __file__ is useful for reading other files and it gives the current location of the ru... |
Python for Data Science- A Guide to Pandas | by Nicholas Leong | Towards Data Science | Hello my fellow data practitioners. It’s been a busy week for me but I’m back.
First of all, I want to personally say thanks to those who had decided to follow me since day 1. I recently hit the 100 follower mark. It is not much, but it truly means the world to me when my content proves to provide value to some random ... | [
{
"code": null,
"e": 251,
"s": 172,
"text": "Hello my fellow data practitioners. It’s been a busy week for me but I’m back."
},
{
"code": null,
"e": 765,
"s": 251,
"text": "First of all, I want to personally say thanks to those who had decided to follow me since day 1. I recently... |
Inplace vs Standard Operators in Python | Inplace operation is an operation which directly changes the content of a given linear algebra or vector or metrices without making a copy. Now the operators, which helps to do this kind of operation is called in-place operator.
Let’s understand it with an a simple example -
a=9
a += 2
print(a)
11
Above the += tie inpu... | [
{
"code": null,
"e": 1291,
"s": 1062,
"text": "Inplace operation is an operation which directly changes the content of a given linear algebra or vector or metrices without making a copy. Now the operators, which helps to do this kind of operation is called in-place operator."
},
{
"code": nu... |
GATE | GATE-CS-2014-(Set-1) | Question 65 - GeeksforGeeks | 30 Sep, 2021
Consider a 6-stage instruction pipeline, where all stages are perfectly balanced. Assume that there is no cycle-time overhead of pipelining. When an application is executing on this 6-stage pipeline, the speedup achieved with respect to non-pipelined execution if 25% of the instructions incur 2 pipeline st... | [
{
"code": null,
"e": 24528,
"s": 24500,
"text": "\n30 Sep, 2021"
},
{
"code": null,
"e": 24892,
"s": 24528,
"text": "Consider a 6-stage instruction pipeline, where all stages are perfectly balanced. Assume that there is no cycle-time overhead of pipelining. When an application is... |
Computer Graphics | The RGB color model - GeeksforGeeks | 19 Mar, 2019
The RGB color model is one of the most widely used color representation method in computer graphics. It use a color coordinate system with three primary colors:
R(red), G(green), B(blue)
Each primary color can take an intensity value ranging from 0(lowest) to 1(highest). Mixing these three primary colors ... | [
{
"code": null,
"e": 24931,
"s": 24903,
"text": "\n19 Mar, 2019"
},
{
"code": null,
"e": 25092,
"s": 24931,
"text": "The RGB color model is one of the most widely used color representation method in computer graphics. It use a color coordinate system with three primary colors:"
... |
How to Install Git on Linux | Git is a popular open source version control system like CVS or SVN. This article is for those, who are not familiar with Git. Here, we are providing you with basic steps of installing Git from source, Creating a new project, and Commit changes to the Git repository.
Most of the other version control systems, store the... | [
{
"code": null,
"e": 1330,
"s": 1062,
"text": "Git is a popular open source version control system like CVS or SVN. This article is for those, who are not familiar with Git. Here, we are providing you with basic steps of installing Git from source, Creating a new project, and Commit changes to the G... |
How to extract a data.table row as a vector in R? | A data.table object is similar to a data frame object but there are few things that can be specifically applied to a data.table because data.table package functions was defined for a data.table object only. If we want to extract a data.table row as a vector then we can use as.vector function along with as.matrix so tha... | [
{
"code": null,
"e": 1425,
"s": 1062,
"text": "A data.table object is similar to a data frame object but there are few things that can be specifically applied to a data.table because data.table package functions was defined for a data.table object only. If we want to extract a data.table row as a ve... |
Critical Connections in a Network in C++ | Suppose there are n servers. And these are numbered from 0 to n-1 connected by an
undirected server-to-server connections forming a network where connections[i] = [a,b]
represents a connection between servers a and b. All servers are connected directly or through some other servers. Now, a critical connection is a conn... | [
{
"code": null,
"e": 1517,
"s": 1062,
"text": "Suppose there are n servers. And these are numbered from 0 to n-1 connected by an\nundirected server-to-server connections forming a network where connections[i] = [a,b]\nrepresents a connection between servers a and b. All servers are connected directl... |
reflect.StructOf() Function in Golang with Examples - GeeksforGeeks | 28 Apr, 2020
Go language provides inbuilt support implementation of run-time reflection and allowing a program to manipulate objects with arbitrary types with the help of reflect package. The reflect.StructOf() Function in Golang is used to get the struct type containing fields. To access this function, one needs to im... | [
{
"code": null,
"e": 25813,
"s": 25785,
"text": "\n28 Apr, 2020"
},
{
"code": null,
"e": 26162,
"s": 25813,
"text": "Go language provides inbuilt support implementation of run-time reflection and allowing a program to manipulate objects with arbitrary types with the help of refle... |
C | Macro & Preprocessor | Question 4 - GeeksforGeeks | 04 Feb, 2013
#include <stdio.h>#define X 3#if !X printf("Geeks");#else printf("Quiz"); #endifint main(){ return 0;}
(A) Geeks(B) Quiz(C) Compiler Error(D) Runtime ErrorAnswer: (C)Explanation: A program is converted to executable using following steps
1) Preprocessing
2) C code to object code conversion
3... | [
{
"code": null,
"e": 25693,
"s": 25665,
"text": "\n04 Feb, 2013"
},
{
"code": "#include <stdio.h>#define X 3#if !X printf(\"Geeks\");#else printf(\"Quiz\"); #endifint main(){ return 0;}",
"e": 25811,
"s": 25693,
"text": null
},
{
"code": null,
"e": 2594... |
C Program for Sum the digits of a given number - GeeksforGeeks | 19 Jul, 2021
Given a number, find sum of its digits.Example :
Input : n = 687
Output : 21
Input : n = 12
Output : 3
1. Iterative:
C
C
// C program to compute sum of digits in// number.# include<stdio.h> /* Function to get sum of digits */int getSum(int n){ int sum = 0; while (n != 0) { sum = sum + n % 1... | [
{
"code": null,
"e": 26200,
"s": 26172,
"text": "\n19 Jul, 2021"
},
{
"code": null,
"e": 26251,
"s": 26200,
"text": "Given a number, find sum of its digits.Example : "
},
{
"code": null,
"e": 26306,
"s": 26251,
"text": "Input : n = 687\nOutput : 21\n\nInput :... |
Triplets with sum with given range | Practice | GeeksforGeeks | Given an array Arr[] of N distinct integers and a range from L to R, the task is to count the number of triplets having a sum in the range [L, R].
Example 1:
Input:
N = 4
Arr = {8 , 3, 5, 2}
L = 7, R = 11
Output: 1
Explaination: There is only one triplet {2, 3, 5}
having sum 10 in range [7, 11].
Example 2:
Input:
N =... | [
{
"code": null,
"e": 385,
"s": 238,
"text": "Given an array Arr[] of N distinct integers and a range from L to R, the task is to count the number of triplets having a sum in the range [L, R]."
},
{
"code": null,
"e": 397,
"s": 385,
"text": "\nExample 1:"
},
{
"code": null... |
ASP.NET - Managing State | Hyper Text Transfer Protocol (HTTP) is a stateless protocol. When the client disconnects from the server, the ASP.NET engine discards the page objects. This way, each web application can scale up to serve numerous requests simultaneously without running out of server memory.
However, there needs to be some technique to... | [
{
"code": null,
"e": 2623,
"s": 2347,
"text": "Hyper Text Transfer Protocol (HTTP) is a stateless protocol. When the client disconnects from the server, the ASP.NET engine discards the page objects. This way, each web application can scale up to serve numerous requests simultaneously without running... |
Algorithms Quiz | Sudo Placement : Set 1 | Question 5 - GeeksforGeeks | 28 Dec, 2020
What will be the output of following C program?
main()
{
char g[] = "geeksforgeeks";
printf("%s", g + g[6] - g[8]);
}
(A) geeks(B) rgeeks(C) geeksforgeeks(D) forgeeksAnswer: (A)Explanation:
char g[] = “geeksforgeeks”;
// g now has the base address string “geeksforgeeks”
// g[6] is ‘o’ and g[1] is ‘e’... | [
{
"code": null,
"e": 24700,
"s": 24672,
"text": "\n28 Dec, 2020"
},
{
"code": null,
"e": 24748,
"s": 24700,
"text": "What will be the output of following C program?"
},
{
"code": null,
"e": 24818,
"s": 24748,
"text": "main()\n{\nchar g[] = \"geeksforgeeks\";\n... |
C++ | Function Overloading and Default Arguments | Question 3 - GeeksforGeeks | 28 Jun, 2021
Which of the following overloaded functions are NOT allowed in C++?
1) Function declarations that differ only in the return type
int fun(int x, int y);
void fun(int x, int y);
2) Functions that differ only by static keyword in return type
int fun(int x, int y);
static int fun(int... | [
{
"code": null,
"e": 25799,
"s": 25771,
"text": "\n28 Jun, 2021"
},
{
"code": null,
"e": 25867,
"s": 25799,
"text": "Which of the following overloaded functions are NOT allowed in C++?"
},
{
"code": null,
"e": 25928,
"s": 25867,
"text": "1) Function declaratio... |
Data Structure and Algorithms - Stack | A stack is an Abstract Data Type (ADT), commonly used in most programming languages. It is named stack as it behaves like a real-world stack, for example – a deck of cards or a pile of plates, etc.
A real-world stack allows operations at one end only. For example, we can place or remove a card or plate from the top of ... | [
{
"code": null,
"e": 2778,
"s": 2580,
"text": "A stack is an Abstract Data Type (ADT), commonly used in most programming languages. It is named stack as it behaves like a real-world stack, for example – a deck of cards or a pile of plates, etc."
},
{
"code": null,
"e": 3046,
"s": 277... |
K Means clustering with python code explained | by Yogesh Chauhan | Towards Data Science | K means clustering is another simplified algorithm in machine learning. It is categorized into unsupervised learning because here we don’t know the result already (no idea about which cluster will be formed). This algorithm is used for vector quantization of the data and has been taken from signal processing methodolog... | [
{
"code": null,
"e": 764,
"s": 172,
"text": "K means clustering is another simplified algorithm in machine learning. It is categorized into unsupervised learning because here we don’t know the result already (no idea about which cluster will be formed). This algorithm is used for vector quantization... |
CSS | blur() Function - GeeksforGeeks | 07 Aug, 2019
The blur() function is an inbuilt function which is used to apply a blurred effect filter on the image.
Syntax:
blur( radius )
Parameters: This function accepts single parameter radius which holds the blur radius in form of length. This parameter defines the value of the standard deviation to the Gaussian ... | [
{
"code": null,
"e": 25296,
"s": 25268,
"text": "\n07 Aug, 2019"
},
{
"code": null,
"e": 25400,
"s": 25296,
"text": "The blur() function is an inbuilt function which is used to apply a blurred effect filter on the image."
},
{
"code": null,
"e": 25408,
"s": 25400,... |
Sum triangle from array - GeeksforGeeks | 10 Jun, 2021
Given an array of integers, print a sum triangle from it such that the first level has all array elements. From then, at each level number of elements is one less than the previous level and elements at the level is be the Sum of consecutive two elements in the previous level. Example :
Input : A = {1, 2,... | [
{
"code": null,
"e": 26175,
"s": 26147,
"text": "\n10 Jun, 2021"
},
{
"code": null,
"e": 26464,
"s": 26175,
"text": "Given an array of integers, print a sum triangle from it such that the first level has all array elements. From then, at each level number of elements is one less ... |
How to get only files but not the folders with Get-ChildItem using PowerShell? | To get only files, you need to use NOT operator in Directory attribute parameter.
Get-ChildItem D:\Temp\ -Attributes !Directory
irectory: D:\Temp
Mode LastWriteTime Length Name
---- ------------- ------ ----
-a---- 07-05-2018 23:00 301 cars.xml
-a---- ... | [
{
"code": null,
"e": 1144,
"s": 1062,
"text": "To get only files, you need to use NOT operator in Directory attribute parameter."
},
{
"code": null,
"e": 1190,
"s": 1144,
"text": "Get-ChildItem D:\\Temp\\ -Attributes !Directory"
},
{
"code": null,
"e": 1952,
"s": ... |
Google SWE Internship 2021 Interview Experience - GeeksforGeeks | 25 Aug, 2020
Hi Geeks, I have applied for Google SWE Internship 2021 (India) and I have been selected and invited for Google’s Online Challenge Round
Application: I have applied through LinkedIn, it is really a great platform for opportunities and I received mail from Google on 12 Aug 2020 and it was a great experien... | [
{
"code": null,
"e": 26301,
"s": 26273,
"text": "\n25 Aug, 2020"
},
{
"code": null,
"e": 26440,
"s": 26301,
"text": "Hi Geeks, I have applied for Google SWE Internship 2021 (India) and I have been selected and invited for Google’s Online Challenge Round "
},
{
"code": nu... |
MCMC Intuition for Everyone. Easy? I tried. | by Rahul Agarwal | Towards Data Science | All of us have heard about the Monte Carlo Markov Chain sometime or other. Sometimes while reading about Bayesian statistics. Sometimes while working with tools like Prophet.
But MCMC is hard to understand. Whenever I read about it, I noticed that the crux is typically hidden in deep layers of Mathematical noise and no... | [
{
"code": null,
"e": 346,
"s": 171,
"text": "All of us have heard about the Monte Carlo Markov Chain sometime or other. Sometimes while reading about Bayesian statistics. Sometimes while working with tools like Prophet."
},
{
"code": null,
"e": 511,
"s": 346,
"text": "But MCMC is... |
Neo4j - Match Clause | In this chapter, we will learn about Match Clause and all the functions that can be performed using this clause.
Using the MATCH clause of Neo4j you can retrieve all nodes in the Neo4j database.
Before proceeding with the example, create 3 nodes and 2 relationships as shown below.
CREATE (Dhoni:player {name: "MahendraS... | [
{
"code": null,
"e": 2452,
"s": 2339,
"text": "In this chapter, we will learn about Match Clause and all the functions that can be performed using this clause."
},
{
"code": null,
"e": 2534,
"s": 2452,
"text": "Using the MATCH clause of Neo4j you can retrieve all nodes in the Neo... |
Find smallest and largest elements in singly linked list in C++ | In this problem, we are given a singly linked list. Our task is to find the
smallest and largest elements in single linked list.
Let’s take an example to understand the problem,
linked List : 5 -> 2 -> 7 -> 3 ->9 -> 1 -> 4
Smallest element = 1
Largest element = 9
A simple solution to the problem is using by traversing ... | [
{
"code": null,
"e": 1191,
"s": 1062,
"text": "In this problem, we are given a singly linked list. Our task is to find the\nsmallest and largest elements in single linked list."
},
{
"code": null,
"e": 1240,
"s": 1191,
"text": "Let’s take an example to understand the problem,"
... |
Collections in C# - GeeksforGeeks | 22 Apr, 2020
Collections standardize the way of which the objects are handled by your program. In other words, it contains a set of classes to contain elements in a generalized manner. With the help of collections, the user can perform several operations on objects like the store, update, delete, retrieve, search, sort... | [
{
"code": null,
"e": 25306,
"s": 25278,
"text": "\n22 Apr, 2020"
},
{
"code": null,
"e": 25619,
"s": 25306,
"text": "Collections standardize the way of which the objects are handled by your program. In other words, it contains a set of classes to contain elements in a generalized... |
List containsAll() method in Java with Examples - GeeksforGeeks | 11 Dec, 2018
The containsAll() method of List interface in Java is used to check if this List contains all of the elements in the specified Collection. So basically it is used to check if a List contains a set of elements or not.
Syntax:
boolean containsAll(Collection col)
Parameters: This method accepts a mandatory pa... | [
{
"code": null,
"e": 24493,
"s": 24465,
"text": "\n11 Dec, 2018"
},
{
"code": null,
"e": 24710,
"s": 24493,
"text": "The containsAll() method of List interface in Java is used to check if this List contains all of the elements in the specified Collection. So basically it is used ... |
Create Toast Message in Java Swing
| A toast message is an alert which disappears with time automatically. With JDK 7, we can create a toast message similar to an alert on android very easily. Following are the steps needed to make a toast message.
Make a rounded rectangle shaped frame. Add a component listener to frame and override the componentResized()... | [
{
"code": null,
"e": 1274,
"s": 1062,
"text": "A toast message is an alert which disappears with time automatically. With JDK 7, we can create a toast message similar to an alert on android very easily. Following are the steps needed to make a toast message."
},
{
"code": null,
"e": 1512... |
Can we override final methods in Java? | Overriding is a one of the mechanisms to achieve polymorphism. This is the case when we have two classes where, one inherits the properties of another using the extends keyword and, these two classes same method including parameters and return type (say, sample).
Since it is inheritance. If we instantiate the subclass ... | [
{
"code": null,
"e": 1326,
"s": 1062,
"text": "Overriding is a one of the mechanisms to achieve polymorphism. This is the case when we have two classes where, one inherits the properties of another using the extends keyword and, these two classes same method including parameters and return type (say... |
Short-circuit evaluation in JavaScript | Short circuit evaluation basically works with the && and || logical operators. The expressions
are evaluated left to right.
For && operator − Short circuit evaluation with &&(AND) logical operator means if the first expression evaluates to false then whole expression will be false and the rest of the expressions will n... | [
{
"code": null,
"e": 1186,
"s": 1062,
"text": "Short circuit evaluation basically works with the && and || logical operators. The expressions\nare evaluated left to right."
},
{
"code": null,
"e": 1399,
"s": 1186,
"text": "For && operator − Short circuit evaluation with &&(AND) l... |
C library function - vfprintf() | The C library function int vfprintf(FILE *stream, const char *format, va_list arg) sends formatted output to a stream using an argument list passed to it.
Following is the declaration for vfprintf() function.
int vfprintf(FILE *stream, const char *format, va_list arg)
stream − This is the pointer to a FILE object that ... | [
{
"code": null,
"e": 2162,
"s": 2007,
"text": "The C library function int vfprintf(FILE *stream, const char *format, va_list arg) sends formatted output to a stream using an argument list passed to it."
},
{
"code": null,
"e": 2216,
"s": 2162,
"text": "Following is the declaratio... |
Groovy - toLowerCase() | Converts all of the characters in this String to lower case.
String toLowerCase()
None
The modified string in lower case.
Following is an example of the usage of this method −
class Example {
static void main(String[] args) {
String a = "HelloWorld";
println(a.toLowerCase());
}
}
When we run the... | [
{
"code": null,
"e": 2299,
"s": 2238,
"text": "Converts all of the characters in this String to lower case."
},
{
"code": null,
"e": 2321,
"s": 2299,
"text": "String toLowerCase()\n"
},
{
"code": null,
"e": 2326,
"s": 2321,
"text": "None"
},
{
"code": ... |
sciPy stats.nanmedian() function | Python - GeeksforGeeks | 11 Feb, 2019
scipy.stats.nanmedian(array, axis=0) function calculates the median by ignoring the Nan (not a number) values of the array elements along the specified axis of the array.
Parameters :array : Input array or object having the elements, including Nan values, to calculate the median.axis : Axis along which the... | [
{
"code": null,
"e": 24234,
"s": 24206,
"text": "\n11 Feb, 2019"
},
{
"code": null,
"e": 24405,
"s": 24234,
"text": "scipy.stats.nanmedian(array, axis=0) function calculates the median by ignoring the Nan (not a number) values of the array elements along the specified axis of the... |
How to get battery level and state in Android? | This example demonstrates how to get battery level and state in Android.
Step 1 - Create a new project in Android Studio, go to File ⇒ New Project and fill all required details to create a new project.
Step 2 - Add the following code to res/layout/activity_main.xml.
<?xml version = "1.0" encoding = "utf-8"?>
<LinearLay... | [
{
"code": null,
"e": 1135,
"s": 1062,
"text": "This example demonstrates how to get battery level and state in Android."
},
{
"code": null,
"e": 1264,
"s": 1135,
"text": "Step 1 - Create a new project in Android Studio, go to File ⇒ New Project and fill all required details to cr... |
Scale, Standardize, or Normalize with Scikit-Learn | by Jeff Hale | Towards Data Science | Many machine learning algorithms work better when features are on a relatively similar scale and close to normally distributed. MinMaxScaler, RobustScaler, StandardScaler, and Normalizer are scikit-learn methods to preprocess data for machine learning. Which method you need, if any, depends on your model type and your ... | [
{
"code": null,
"e": 507,
"s": 171,
"text": "Many machine learning algorithms work better when features are on a relatively similar scale and close to normally distributed. MinMaxScaler, RobustScaler, StandardScaler, and Normalizer are scikit-learn methods to preprocess data for machine learning. Wh... |
Java labelled statement | Yes. Java supports labeled statements. You can put a label before a for statement and use the break/continue controls to jump to that label.
See the example below.
Live Demo
public class Tester {
public static void main(String args[]) {
first:
for (int i = 0; i < 3; i++) {
for (int j = 0... | [
{
"code": null,
"e": 1204,
"s": 1062,
"text": "Yes. Java supports labeled statements. You can put a label before a for statement and use the break/continue controls to jump to that label. "
},
{
"code": null,
"e": 1227,
"s": 1204,
"text": "See the example below."
},
{
"co... |
break, continue and pass in Python - GeeksforGeeks | 25 Nov, 2019
Using loops in Python automates and repeats the tasks in an efficient manner. But sometimes, there may arise a condition where you want to exit the loop completely, skip an iteration or ignore that condition. These can be done by loop control statements. Loop control statements change execution from its no... | [
{
"code": null,
"e": 23927,
"s": 23899,
"text": "\n25 Nov, 2019"
},
{
"code": null,
"e": 24399,
"s": 23927,
"text": "Using loops in Python automates and repeats the tasks in an efficient manner. But sometimes, there may arise a condition where you want to exit the loop completely... |
Python Trading Toolbox: step up your charts with indicator subplots | by Stefano Basurto | Towards Data Science | After a several months-long hiatus, I can finally resume posting to the Trading Toolbox Series. We started this series by learning how to plot indicators (specifically: moving averages) on the top of a price chart. Moving averages belong to a wide group of indicators, called overlay indicators, that share the same scal... | [
{
"code": null,
"e": 694,
"s": 172,
"text": "After a several months-long hiatus, I can finally resume posting to the Trading Toolbox Series. We started this series by learning how to plot indicators (specifically: moving averages) on the top of a price chart. Moving averages belong to a wide group o... |
How to plot one single data point in Matplotlib? | To plot one single data point in matplotlib, we can take the following steps −
Initialize a list for x and y, with a single value.
Initialize a list for x and y, with a single value.
Limit x and y axis range for 0 to 5.
Limit x and y axis range for 0 to 5.
Lay out a grid in current line style.
Lay out a grid in current... | [
{
"code": null,
"e": 1141,
"s": 1062,
"text": "To plot one single data point in matplotlib, we can take the following steps −"
},
{
"code": null,
"e": 1193,
"s": 1141,
"text": "Initialize a list for x and y, with a single value."
},
{
"code": null,
"e": 1245,
"s":... |
Elixir - Basic Syntax | We will start with the customary 'Hello World' program.
To start the Elixir interactive shell, enter the following command.
iex
After the shell starts, use the IO.puts function to "put" the string on the console output. Enter the following in your Elixir shell −
IO.puts "Hello world"
In this tutorial, we will use the ... | [
{
"code": null,
"e": 2238,
"s": 2182,
"text": "We will start with the customary 'Hello World' program."
},
{
"code": null,
"e": 2306,
"s": 2238,
"text": "To start the Elixir interactive shell, enter the following command."
},
{
"code": null,
"e": 2311,
"s": 2306,
... |
JUnit - Basic Usage | Let us now have a basic example to demonstrate the step-by-step process of using JUnit.
Create a java class to be tested, say, MessageUtil.java in C:\>JUNIT_WORKSPACE
/*
* This class prints the given message on console.
*/
public class MessageUtil {
private String message;
//Constructor
//@param message to ... | [
{
"code": null,
"e": 2060,
"s": 1972,
"text": "Let us now have a basic example to demonstrate the step-by-step process of using JUnit."
},
{
"code": null,
"e": 2139,
"s": 2060,
"text": "Create a java class to be tested, say, MessageUtil.java in C:\\>JUNIT_WORKSPACE"
},
{
... |
Working with datetime in Pandas DataFrame | by B. Chen | Towards Data Science | Datetime is a common data type in data science projects. Often, you’ll work with it and run into problems. I found Pandas is an amazing library that contains extensive capabilities and features for working with date and time.
In this article, we will cover the following common datetime problems and should help you get ... | [
{
"code": null,
"e": 398,
"s": 172,
"text": "Datetime is a common data type in data science projects. Often, you’ll work with it and run into problems. I found Pandas is an amazing library that contains extensive capabilities and features for working with date and time."
},
{
"code": null,
... |
Create new linked list from two given linked list with greater element at each node - GeeksforGeeks | 28 Mar, 2022
Given two linked list of the same size, the task is to create a new linked list using those linked lists. The condition is that the greater node among both linked list will be added to the new linked list.Examples:
Input: list1 = 5->2->3->8
list2 = 1->7->4->5
Output: New list = 5->7->4->8
Input: list1... | [
{
"code": null,
"e": 24656,
"s": 24628,
"text": "\n28 Mar, 2022"
},
{
"code": null,
"e": 24873,
"s": 24656,
"text": "Given two linked list of the same size, the task is to create a new linked list using those linked lists. The condition is that the greater node among both linked ... |
Longest Arithmetic Progression | Practice | GeeksforGeeks | Given an array called A[] of sorted integers having no duplicates, find the length of the Longest Arithmetic Progression (LLAP) in it.
Example 1:
Input:
N = 6
set[] = {1, 7, 10, 13, 14, 19}
Output: 4
Explanation: The longest arithmetic
progression is {1, 7, 13, 19}.
Example 2:
Input:
N = 5
A[] = {2, 4, 6, 8, 10}
Out... | [
{
"code": null,
"e": 373,
"s": 238,
"text": "Given an array called A[] of sorted integers having no duplicates, find the length of the Longest Arithmetic Progression (LLAP) in it."
},
{
"code": null,
"e": 385,
"s": 373,
"text": "\nExample 1:"
},
{
"code": null,
"e": 5... |
Install Python package using Jupyter Notebook - GeeksforGeeks | 06 Mar, 2020
Jupyter Notebook is an open-source web application that is used to create and share documents that contain data in different formats which includes live code, equations, visualizations, and text. Uses include data cleaning and transformation, numerical simulation, statistical modeling, data visualization, ... | [
{
"code": null,
"e": 25665,
"s": 25637,
"text": "\n06 Mar, 2020"
},
{
"code": null,
"e": 26005,
"s": 25665,
"text": "Jupyter Notebook is an open-source web application that is used to create and share documents that contain data in different formats which includes live code, equa... |
Array Manipulation and Sum - GeeksforGeeks | 02 Aug, 2021
Given an array arr[] of N integers and an integer S. The task is to find an element K in the array such that if all the elements from the array > K are made equal to K then the sum of all the elements of the resultant array becomes equal to S. If it is not possible to find such an element then print -1 .Ex... | [
{
"code": null,
"e": 24300,
"s": 24272,
"text": "\n02 Aug, 2021"
},
{
"code": null,
"e": 24617,
"s": 24300,
"text": "Given an array arr[] of N integers and an integer S. The task is to find an element K in the array such that if all the elements from the array > K are made equal ... |
GATE | GATE-CS-2015 (Set 1) | Question 65 - GeeksforGeeks | 28 Jun, 2021
Which one of the following combinations is incorrect?(A) Acquiescence – Submission(B) Wheedle – Roundabout(C) Flippancy – Lightness(D) Profligate – ExtravagantAnswer: (B)Explanation:
Flippancy ---> lack of respect or seriousness.
Acquiescence ---> the reluctant acceptance of
someth... | [
{
"code": null,
"e": 24544,
"s": 24516,
"text": "\n28 Jun, 2021"
},
{
"code": null,
"e": 24727,
"s": 24544,
"text": "Which one of the following combinations is incorrect?(A) Acquiescence – Submission(B) Wheedle – Roundabout(C) Flippancy – Lightness(D) Profligate – ExtravagantAnsw... |
Including an external stylesheet file in your HTML document | The <link> element can be used to include an external style sheet file in your HTML document.
An external style sheet is a separate text file with .css extension. You define all the Style rules within this text file and then you can include this file in any HTML document using <link> element.
Consider a simple style sh... | [
{
"code": null,
"e": 1156,
"s": 1062,
"text": "The <link> element can be used to include an external style sheet file in your HTML document."
},
{
"code": null,
"e": 1356,
"s": 1156,
"text": "An external style sheet is a separate text file with .css extension. You define all the ... |
How to preserve leading 0 with JavaScript numbers? | There’s no way to preserve the leading 0 in JavaScript. However, you can consider this id as a string and pass as an argument.
You can try to run the following code to preserve leading 0 by making it a string −
Live Demo
<html>
<head>
<script>
function sayHello(name, age, id) {
document.wr... | [
{
"code": null,
"e": 1189,
"s": 1062,
"text": "There’s no way to preserve the leading 0 in JavaScript. However, you can consider this id as a string and pass as an argument."
},
{
"code": null,
"e": 1273,
"s": 1189,
"text": "You can try to run the following code to preserve leadi... |
The Correct Way to Measure Inference Time of Deep Neural Networks | by Amnon Geifman | Towards Data Science | The network latency is one of the more crucial aspects of deploying a deep network into a production environment. Most real-world applications require blazingly fast inference time, varying anywhere from a few milliseconds to one second. But the task of correctly and meaningfully measuring the inference time, or latenc... | [
{
"code": null,
"e": 752,
"s": 171,
"text": "The network latency is one of the more crucial aspects of deploying a deep network into a production environment. Most real-world applications require blazingly fast inference time, varying anywhere from a few milliseconds to one second. But the task of c... |
Espresso Testing Framework - Test Recorder | Writing test case is a tedious job. Even though espresso provides very easy and flexible API, writing test cases may be a lazy and time-consuming task. To overcome this, Android studio provides a feature to record and generate espresso test cases. Record Espresso Test is available under the Run menu.
Let us record a si... | [
{
"code": null,
"e": 2278,
"s": 1976,
"text": "Writing test case is a tedious job. Even though espresso provides very easy and flexible API, writing test cases may be a lazy and time-consuming task. To overcome this, Android studio provides a feature to record and generate espresso test cases. Recor... |
How to Create Animate Graphs in Python | Towards Data Science | As data is forever expanding at unprecedented rates, data scientists are called upon to analyse it and make sense of it. Once that happens, there comes the need for effectively communicating the results.
Communicating the results of data analysis, however, can often be tricky. To effectively communicate, a popular and ... | [
{
"code": null,
"e": 375,
"s": 171,
"text": "As data is forever expanding at unprecedented rates, data scientists are called upon to analyse it and make sense of it. Once that happens, there comes the need for effectively communicating the results."
},
{
"code": null,
"e": 538,
"s": ... |
Java DatabaseMetaData getUserName() method with example | This method retrieves the user name used to establish the current connection −
To retrieve the user name as known to the database −
Make sure your database is up and running.
Make sure your database is up and running.
Register the driver using the registerDriver() method of the DriverManager class. Pass an object of th... | [
{
"code": null,
"e": 1141,
"s": 1062,
"text": "This method retrieves the user name used to establish the current connection −"
},
{
"code": null,
"e": 1194,
"s": 1141,
"text": "To retrieve the user name as known to the database −"
},
{
"code": null,
"e": 1237,
"s"... |
My top 4 functions to style the Pandas Dataframe | by Cornellius Yudha Wijaya | Towards Data Science | Pandas Dataframe is the most used object for Data scientists to analyze their data. While the main function is to just place your data and get on with the analysis, we could still style our data frame for many purposes; namely, for presenting data or better aesthetic.
Let’s take an example with a dataset. I would use t... | [
{
"code": null,
"e": 441,
"s": 172,
"text": "Pandas Dataframe is the most used object for Data scientists to analyze their data. While the main function is to just place your data and get on with the analysis, we could still style our data frame for many purposes; namely, for presenting data or bett... |
Implementing PCA from Scratch. Compare the implementation with... | by Eugenia Anello | Towards Data Science | This article is in continuation with the story Variable Reduction with Principal Component Analysis. In the previous post, I talked about one of the most known and widely used methods, called Principal Component Analysis. It employs an efficient linear transformation, which reduces the dimensionality of a high dimensio... | [
{
"code": null,
"e": 1196,
"s": 172,
"text": "This article is in continuation with the story Variable Reduction with Principal Component Analysis. In the previous post, I talked about one of the most known and widely used methods, called Principal Component Analysis. It employs an efficient linear t... |
Add a single element to a LinkedList in Java | A single element can be added to a LinkedList by using the java.util.LinkedList.add() method. This method has one parameter parameters i.e. the element that is to be inserted in the LinkedList.
A program that demonstrates this is given as follows −
Live Demo
import java.util.LinkedList;
public class Demo {
public s... | [
{
"code": null,
"e": 1256,
"s": 1062,
"text": "A single element can be added to a LinkedList by using the java.util.LinkedList.add() method. This method has one parameter parameters i.e. the element that is to be inserted in the LinkedList."
},
{
"code": null,
"e": 1311,
"s": 1256,
... |
Program to convert Milliseconds to Date Format in Java | Let us first declare and initialize milliseconds value variable −
long milliSeconds = 656478;
Now, convert Milliseconds to Date format −
DateFormat dateFormat = new SimpleDateFormat("dd MMM yyyy HH:mm:ss:SSS Z");
Date date = new Date(milliSeconds);
Following is the program to convert Milliseconds to Date Format in Java... | [
{
"code": null,
"e": 1128,
"s": 1062,
"text": "Let us first declare and initialize milliseconds value variable −"
},
{
"code": null,
"e": 1156,
"s": 1128,
"text": "long milliSeconds = 656478;"
},
{
"code": null,
"e": 1199,
"s": 1156,
"text": "Now, convert Mill... |
What is encapsulation in Java? | Encapsulation in Java is a mechanism for wrapping the data (variables) and code acting on the data (methods) together as a single unit. In encapsulation, the variables of a class will be hidden from other classes and can be accessed only through the methods of their current class. Therefore, it is also known as data hi... | [
{
"code": null,
"e": 1388,
"s": 1062,
"text": "Encapsulation in Java is a mechanism for wrapping the data (variables) and code acting on the data (methods) together as a single unit. In encapsulation, the variables of a class will be hidden from other classes and can be accessed only through the met... |
C++ Library - <functional> | Function objects are objects specifically designed to be used with a syntax similar to that of functions. Instances of std::function can store, copy, and invoke any Callable target -- functions, lambda expressions, bind expressions, or other function objects, as well as pointers to member functions and pointers to data... | [
{
"code": null,
"e": 2933,
"s": 2603,
"text": "Function objects are objects specifically designed to be used with a syntax similar to that of functions. Instances of std::function can store, copy, and invoke any Callable target -- functions, lambda expressions, bind expressions, or other function ob... |
ConcurrentLinkedQueue in Java with Examples - GeeksforGeeks | 26 May, 2021
The ConcurrentLinkedQueue class in Java is a part of the Java Collection Framework. It belongs to java.util.concurrent package. It was introduced in JDK 1.5. It is used to implement Queue with the help of LinkedList concurrently. It is an unbounded thread-safe implementation of Queue which inserts elements... | [
{
"code": null,
"e": 24372,
"s": 24344,
"text": "\n26 May, 2021"
},
{
"code": null,
"e": 25009,
"s": 24372,
"text": "The ConcurrentLinkedQueue class in Java is a part of the Java Collection Framework. It belongs to java.util.concurrent package. It was introduced in JDK 1.5. It is... |
Predicting Who’s going to Survive on Titanic Dataset | by Vincent Tatan | Towards Data Science | All aboard!! Embark your Data Journey With Titanic
Welcome to Data Science SS. My name is Vincent and hopefully you will enjoy our first journey to Data Science. Today, we are going to sail in the Atlantic Ocean with our fallen comrade, the Titanic. We are going to carefully explore the data icebergs, sail the Machine ... | [
{
"code": null,
"e": 222,
"s": 171,
"text": "All aboard!! Embark your Data Journey With Titanic"
},
{
"code": null,
"e": 612,
"s": 222,
"text": "Welcome to Data Science SS. My name is Vincent and hopefully you will enjoy our first journey to Data Science. Today, we are going to s... |
HTML <datalist> Tag | 17 Mar, 2022
The <datalist> tag is used to provide autocomplete feature in the HTML files. It can be used with an input tag so that users can easily fill the data in the forms using select the data.Syntax:
<datalist> ... </datalist>
Example 1: The below code explains datalist Tag.
HTML
<!DOCTYPE html><html><body> <f... | [
{
"code": null,
"e": 52,
"s": 24,
"text": "\n17 Mar, 2022"
},
{
"code": null,
"e": 245,
"s": 52,
"text": "The <datalist> tag is used to provide autocomplete feature in the HTML files. It can be used with an input tag so that users can easily fill the data in the forms using selec... |
Waits in Selenium Python | 08 Jun, 2020
Selenium Python is one of the great tools for testing automation. These days most of the web apps are using AJAX techniques. When a page is loaded by the browser, the elements within that page may load at different time intervals. This makes locating elements difficult: if an element is not yet present in ... | [
{
"code": null,
"e": 53,
"s": 25,
"text": "\n08 Jun, 2020"
},
{
"code": null,
"e": 650,
"s": 53,
"text": "Selenium Python is one of the great tools for testing automation. These days most of the web apps are using AJAX techniques. When a page is loaded by the browser, the element... |
GATE | GATE-CS-2006 | Question 32 | 28 Jun, 2021
Consider the following statements about the context free grammar
G = {S → SS, S → ab, S → ba, S → Ε}
I. G is ambiguous
II. G produces all strings with equal number of a’s and b’s
III. G can be accepted by a deterministic PDA.
Which combination below expresses all the true statements about G?(A) I only(B) I... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n28 Jun, 2021"
},
{
"code": null,
"e": 93,
"s": 28,
"text": "Consider the following statements about the context free grammar"
},
{
"code": null,
"e": 254,
"s": 93,
"text": "G = {S → SS, S → ab, S → ba, S → Ε}\nI. G i... |
Java.io.PipedInputStream class in Java | 13 Oct, 2021
Pipes in IO provides a link between two threads running in JVM at the same time. So, Pipes are used both as source or destination.
PipedInputStream is also piped with PipedOutputStream. So, data can be written using PipedOutputStream and can be written using PipedInputStream.But, using both threads at the ... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n13 Oct, 2021"
},
{
"code": null,
"e": 159,
"s": 28,
"text": "Pipes in IO provides a link between two threads running in JVM at the same time. So, Pipes are used both as source or destination."
},
{
"code": null,
"e": 385,
... |
Klee’s Algorithm (Length Of Union Of Segments of a line) | 16 Jun, 2022
Given starting and ending positions of segments on a line, the task is to take the union of all given segments and find length covered by these segments.Examples:
Input : segments[] = {{2, 5}, {4, 8}, {9, 12}}
Output : 9
Explanation:
segment 1 = {2, 5}
segment 2 = {4, 8}
segment 3 = {9, 12}
If we take t... | [
{
"code": null,
"e": 54,
"s": 26,
"text": "\n16 Jun, 2022"
},
{
"code": null,
"e": 219,
"s": 54,
"text": "Given starting and ending positions of segments on a line, the task is to take the union of all given segments and find length covered by these segments.Examples: "
},
{... |
Windows Anonymous Pipe | Windows anonymous pipes are actually Ordinary pipes, and they behave similarly to their UNIX counterparts: they are unidirectional and employ parent-child relationships between the communicating processes. In addition, reading and writing to the pipe can be accomplished with the ordinary ReadFile() and WriteFile() func... | [
{
"code": null,
"e": 1528,
"s": 1062,
"text": "Windows anonymous pipes are actually Ordinary pipes, and they behave similarly to their UNIX counterparts: they are unidirectional and employ parent-child relationships between the communicating processes. In addition, reading and writing to the pipe ca... |
Introduction to BigQuery ML. Learn how to create machine learning... | by Pol Ferrando | Towards Data Science | A few months ago Google announced a new Google BigQuery feature called BigQuery ML, which is currently in Beta. It consists of a set of extensions of the SQL language that allows to create machine learning models, evaluate their predictive performance and make predictions for new data directly in BigQuery.
One of the a... | [
{
"code": null,
"e": 480,
"s": 172,
"text": "A few months ago Google announced a new Google BigQuery feature called BigQuery ML, which is currently in Beta. It consists of a set of extensions of the SQL language that allows to create machine learning models, evaluate their predictive performance and... |
Android - Services | Started
A service is started when an application component, such as an activity, starts it by calling startService(). Once started, a service can run in the background indefinitely, even if the component that started it is destroyed.
Bound
A service is bound when an application component binds to it by calling bindServ... | [
{
"code": null,
"e": 3615,
"s": 3607,
"text": "Started"
},
{
"code": null,
"e": 3841,
"s": 3615,
"text": "A service is started when an application component, such as an activity, starts it by calling startService(). Once started, a service can run in the background indefinitely, ... |
How to Use Random Seeds Effectively | by Jai Bansal | Towards Data Science | Building a predictive model is a complex process. You need to get the right data, clean it, create useful features, test different algorithms, and finally validate your model’s performance. However, this post covers an aspect of the model-building process that doesn’t typically get much attention: random seeds.
A rando... | [
{
"code": null,
"e": 484,
"s": 171,
"text": "Building a predictive model is a complex process. You need to get the right data, clean it, create useful features, test different algorithms, and finally validate your model’s performance. However, this post covers an aspect of the model-building process... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.