title stringlengths 3 221 | text stringlengths 17 477k | parsed listlengths 0 3.17k |
|---|---|---|
Python 3 - Tkinter Canvas | The Canvas is a rectangular area intended for drawing pictures or other complex layouts. You can place graphics, text, widgets or frames on a Canvas.
Here is the simple syntax to create this widget −
w = Canvas ( master, option = value, ... )
master − This represents the parent window.
master − This represents the par... | [
{
"code": null,
"e": 2490,
"s": 2340,
"text": "The Canvas is a rectangular area intended for drawing pictures or other complex layouts. You can place graphics, text, widgets or frames on a Canvas."
},
{
"code": null,
"e": 2540,
"s": 2490,
"text": "Here is the simple syntax to cre... |
Python Set | update() | 08 Oct, 2021
Python update() function in set adds elements from a set (passed as an argument) to the set.
Syntax : set1.update(set2)
Here set1 is the set in which set2 will be added.
Parameters : Update() method takes only a single argument. The single argument can be a set, list, tuples or a dictionary. It automati... | [
{
"code": null,
"e": 52,
"s": 24,
"text": "\n08 Oct, 2021"
},
{
"code": null,
"e": 146,
"s": 52,
"text": "Python update() function in set adds elements from a set (passed as an argument) to the set. "
},
{
"code": null,
"e": 175,
"s": 146,
"text": "Syntax : s... |
Pong Game in JavaScript | 22 Feb, 2021
Pong game is a two-player table tennis-themed video game. The game involves two paddles and a moving ball. The players have to move paddles in an upwards or downwards direction and save the ball from getting hit onto the wall. If the ball hits the wall then it’s a score for another player.
Prerequisite: Mu... | [
{
"code": null,
"e": 54,
"s": 26,
"text": "\n22 Feb, 2021"
},
{
"code": null,
"e": 345,
"s": 54,
"text": "Pong game is a two-player table tennis-themed video game. The game involves two paddles and a moving ball. The players have to move paddles in an upwards or downwards directi... |
Hashtable contains() Method in Java | 28 Jun, 2018
The java.util.Hashtable.contains(Object value) method in Java is used to check whether a particular value is being mapped by any keys present in the Hashtable.
Syntax:
Hash_table.contains(Object value)
Parameters: The method accepts one parameter value of object type and refers to the value of the hashtabl... | [
{
"code": null,
"e": 52,
"s": 24,
"text": "\n28 Jun, 2018"
},
{
"code": null,
"e": 212,
"s": 52,
"text": "The java.util.Hashtable.contains(Object value) method in Java is used to check whether a particular value is being mapped by any keys present in the Hashtable."
},
{
... |
Matplotlib - Contour Plot | Contour plots (sometimes called Level Plots) are a way to show a three-dimensional surface on a two-dimensional plane. It graphs two predictor variables X Y on the y-axis and a response variable Z as contours. These contours are sometimes called the z-slices or the iso-response values.
A contour plot is appropriate if ... | [
{
"code": null,
"e": 2937,
"s": 2650,
"text": "Contour plots (sometimes called Level Plots) are a way to show a three-dimensional surface on a two-dimensional plane. It graphs two predictor variables X Y on the y-axis and a response variable Z as contours. These contours are sometimes called the z-s... |
Java AWT | Dimension Class | 05 Jul, 2022
Dimension class is a part of Java AWT. It contains the height and width of a component in an integer as well as double precision. The use of Dimension class is that many functions of Java AWT and Swing return dimension object.
Constructors of the Dimension class
Dimension() : It will create a new Object ... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n05 Jul, 2022"
},
{
"code": null,
"e": 256,
"s": 28,
"text": "Dimension class is a part of Java AWT. It contains the height and width of a component in an integer as well as double precision. The use of Dimension class is that many funct... |
GATE | GATE-CS-2016 (Set 2) | Question 42 | 29 Sep, 2021
The width of the physical address on a machine is 40 bits. The width of the tag field in a 512 KB 8-way set associative cache is ____________ bits(A) 24(B) 20(C) 30(D) 40Answer: (A)Explanation: An easy approach would be we know that physical address is 40 bytes
We know cache size = no.of.sets*
... | [
{
"code": null,
"e": 52,
"s": 24,
"text": "\n29 Sep, 2021"
},
{
"code": null,
"e": 314,
"s": 52,
"text": "The width of the physical address on a machine is 40 bits. The width of the tag field in a 512 KB 8-way set associative cache is ____________ bits(A) 24(B) 20(C) 30(D) 40Answ... |
Python – Update dictionary with other dictionary | 10 May, 2020
Sometimes, while working with Python dictionaries, we can have problem in which we need to perform the update of dictionary with other keys of dictionary. This can have applications in domains in which we need to add certain records to previously captured records. Let’s discuss certain ways in which this t... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n10 May, 2020"
},
{
"code": null,
"e": 357,
"s": 28,
"text": "Sometimes, while working with Python dictionaries, we can have problem in which we need to perform the update of dictionary with other keys of dictionary. This can have applic... |
How to set the button alignment in Bootstrap ? | 19 Jun, 2019
Bootstrap buttons are no different from any other DOM elements of an HTML document. Aligning them is more likely the same as aligning paragraphs, divs and sections. Here are some of the scenarios that one can encounter.
.text-left
.text-center
.text-right
Syntax:
class="text-left"|"text-center"|"text-right... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n19 Jun, 2019"
},
{
"code": null,
"e": 248,
"s": 28,
"text": "Bootstrap buttons are no different from any other DOM elements of an HTML document. Aligning them is more likely the same as aligning paragraphs, divs and sections. Here are s... |
Walmart Interview Experience | On-Campus August 2020 (Virtual) | 09 Dec, 2020
Round 1(Online-Written): Platform was HackerEarth time duration was 1 hour.
25 MCQs (Both Easy and Gate Level Based) 1 Coding Question, that needs to be solved in O(logn) time. Program for Fibonacci numbers. The basic idea behind that question is we need to crack the pattern and then based on constraints... | [
{
"code": null,
"e": 52,
"s": 24,
"text": "\n09 Dec, 2020"
},
{
"code": null,
"e": 130,
"s": 52,
"text": "Round 1(Online-Written): Platform was HackerEarth time duration was 1 hour. "
},
{
"code": null,
"e": 381,
"s": 130,
"text": "25 MCQs (Both Easy and Gate... |
Working with Page Orientations and Pagination Properties – Python .docx Module | 09 Jul, 2021
Prerequisite: Working with .docx module
Word documents contain formatted text wrapped within three object levels. The Lowest level- run objects, middle level- paragraph objects, and highest level- document object. So, we cannot work with these documents using normal text editors. But, we can manipulate the... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n09 Jul, 2021"
},
{
"code": null,
"e": 68,
"s": 28,
"text": "Prerequisite: Working with .docx module"
},
{
"code": null,
"e": 432,
"s": 68,
"text": "Word documents contain formatted text wrapped within three object le... |
How to Install Packages in Python on Linux? | 23 Sep, 2021
To install a package in python, we use pip. The pip is a python package manager. In this tutorial, we will be discussing how we can install packages in python on a Linux system.
To install packages in python on Linux, we must have python and pip installed on our Linux machine. As python comes preinstalled ... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n23 Sep, 2021"
},
{
"code": null,
"e": 206,
"s": 28,
"text": "To install a package in python, we use pip. The pip is a python package manager. In this tutorial, we will be discussing how we can install packages in python on a Linux syste... |
Practice Problems on Hashing | 08 Jul, 2021
In this article, we will discuss the types of questions based on hashing. Before understanding this, you should have idea about hashing, hash function, open addressing and chaining techniques (see: Introduction, Separate chaining, Open addressing).
These are some key points in hashing:
The purpose of ha... | [
{
"code": null,
"e": 52,
"s": 24,
"text": "\n08 Jul, 2021"
},
{
"code": null,
"e": 302,
"s": 52,
"text": "In this article, we will discuss the types of questions based on hashing. Before understanding this, you should have idea about hashing, hash function, open addressing and ch... |
Python program to calculate the number of digits and letters in a string | 29 Jun, 2022
Prerequisites: isnumeric() method – Python
Given a string, containing digits and letters, the task is to write a Python program to calculate the number of digits and letters in a string. The following block expresses the basic idea behind it:
Input: string = "geeks2for3geeks"
Output: total digits = 2 and t... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n29 Jun, 2022"
},
{
"code": null,
"e": 71,
"s": 28,
"text": "Prerequisites: isnumeric() method – Python"
},
{
"code": null,
"e": 271,
"s": 71,
"text": "Given a string, containing digits and letters, the task is to wri... |
Encrypt the given string with the following operations | 10 Jun, 2021
Given a string s, the task is to encrypt the string in the following way:
If the frequency of current character is even, then increment current character by x.If the frequency of current character is odd, then decrement current character by x.
If the frequency of current character is even, then increment ... | [
{
"code": null,
"e": 54,
"s": 26,
"text": "\n10 Jun, 2021"
},
{
"code": null,
"e": 129,
"s": 54,
"text": "Given a string s, the task is to encrypt the string in the following way: "
},
{
"code": null,
"e": 299,
"s": 129,
"text": "If the frequency of current ch... |
Generalization and Specialization in Java | 27 Jun, 2022
Loosely speaking, a class which tells the main features but not the specific details. The classes situated at the top of the inheritance hierarchy can be said as General.
A class which is very particular and states the specific details. The classes situated at the bottom of the inheritance hierarchy can be... | [
{
"code": null,
"e": 52,
"s": 24,
"text": "\n27 Jun, 2022"
},
{
"code": null,
"e": 223,
"s": 52,
"text": "Loosely speaking, a class which tells the main features but not the specific details. The classes situated at the top of the inheritance hierarchy can be said as General."
... |
How to check if URL contain certain string using PHP? | 08 Feb, 2019
Given a URL and the task is to check the URL contains certain string or not. The URL are basically the strings. So in order to check the existence of certain strings, two approaches can be followed. The first approach is used to find the sub string matching in a string and second approach is to find a regu... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n08 Feb, 2019"
},
{
"code": null,
"e": 404,
"s": 28,
"text": "Given a URL and the task is to check the URL contains certain string or not. The URL are basically the strings. So in order to check the existence of certain strings, two appr... |
SciPy - Quick Guide | SciPy, pronounced as Sigh Pi, is a scientific python open source, distributed under the BSD licensed library to perform Mathematical, Scientific and Engineering Computations.
The SciPy library depends on NumPy, which provides convenient and fast N-dimensional array manipulation. The SciPy library is built to work with ... | [
{
"code": null,
"e": 2196,
"s": 2021,
"text": "SciPy, pronounced as Sigh Pi, is a scientific python open source, distributed under the BSD licensed library to perform Mathematical, Scientific and Engineering Computations."
},
{
"code": null,
"e": 2702,
"s": 2196,
"text": "The Sci... |
Laravel | 25 Aug, 2021
What is Laravel ?
Laravel is a web application framework created by Taylor Otwell in 2011 and like all other modern frameworks, it also follows the Model-View-Controller (MVC) architectural pattern. Laravel values Elegance, Simplicity, and Readability and if one talks of building applications with PHP fram... | [
{
"code": null,
"e": 54,
"s": 26,
"text": "\n25 Aug, 2021"
},
{
"code": null,
"e": 72,
"s": 54,
"text": "What is Laravel ?"
},
{
"code": null,
"e": 396,
"s": 72,
"text": "Laravel is a web application framework created by Taylor Otwell in 2011 and like all othe... |
SQL Query to Update From One Table to Another Based on an ID Match | 28 Oct, 2021
In this article, we will see, how to update from one table to another table based on ID match. We can update the table using UPDATE statement in SQL. The update statement is always followed by the SET command. The SET command is used to specify which columns and values need to be updated in a table.
UPDATE... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n28 Oct, 2021"
},
{
"code": null,
"e": 329,
"s": 28,
"text": "In this article, we will see, how to update from one table to another table based on ID match. We can update the table using UPDATE statement in SQL. The update statement is a... |
Reverse bytes of a Hexadecimal Number | 04 Jul, 2022
Given an unsigned integer N. The task is to reverse all bytes of N without using a temporary variable and print the reversed number. Examples:
Input: N = 0xaabbccdd Output: 0xddccbbaa Input: N = 0xa912cbd4 Output: 0xd4cb12a9
The naive approach is to extract the appropriate byte is to use mask(&) with shift... | [
{
"code": null,
"e": 52,
"s": 24,
"text": "\n04 Jul, 2022"
},
{
"code": null,
"e": 195,
"s": 52,
"text": "Given an unsigned integer N. The task is to reverse all bytes of N without using a temporary variable and print the reversed number. Examples:"
},
{
"code": null,
... |
Test Oracles | 24 Mar, 2022
Test Oracle is a mechanism, different from the program itself, that can be used to test the accuracy of a program’s output for test cases. Conceptually, we can consider testing a process in which test cases are given for testing and the program under test. The output of the two then compares to determine w... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n24 Mar, 2022"
},
{
"code": null,
"e": 414,
"s": 28,
"text": "Test Oracle is a mechanism, different from the program itself, that can be used to test the accuracy of a program’s output for test cases. Conceptually, we can consider testin... |
How to handle right-to-left and left-to-right swipe gestures on Android? | This example demonstrates how do I handle right to left and left to right swipe gestures on 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" encod... | [
{
"code": null,
"e": 1288,
"s": 1187,
"text": "This example demonstrates how do I handle right to left and left to right swipe gestures on android."
},
{
"code": null,
"e": 1417,
"s": 1288,
"text": "Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and fil... |
GATE | GATE-CS-2016 (Set 2) | Question 23 | 28 Jun, 2021
Assume that the algorithms considered here sort the input sequences in ascending order. If the input is already in ascending order, which of the following are TRUE ?
I. Quicksort runs in Θ(n2) time
II. Bubblesort runs in Θ(n2) time
III. Mergesort runs in Θ(n) time
IV. Insertion sort runs in Θ(n) time... | [
{
"code": null,
"e": 52,
"s": 24,
"text": "\n28 Jun, 2021"
},
{
"code": null,
"e": 218,
"s": 52,
"text": "Assume that the algorithms considered here sort the input sequences in ascending order. If the input is already in ascending order, which of the following are TRUE ?"
},
... |
How to implement a function “getScript” that fetches/executes a JavaScript file in browser ? | 12 Mar, 2021
In this article, we will learn how to fetch a JavaScript file(.js) and load it in a web browser dynamically by using JavaScript with HTML. We need a web browser i.e., Chrome (recommended) or Electron Application. Sometimes we need to add a script in the document as per the requirement of the user interface... | [
{
"code": null,
"e": 52,
"s": 24,
"text": "\n12 Mar, 2021"
},
{
"code": null,
"e": 407,
"s": 52,
"text": "In this article, we will learn how to fetch a JavaScript file(.js) and load it in a web browser dynamically by using JavaScript with HTML. We need a web browser i.e., Chrome ... |
SQL | Procedures in PL/SQL | 21 Mar, 2018
PL/SQL is a block-structured language that enables developers to combine the power of SQL with procedural statements.A stored procedure in PL/SQL is nothing but a series of declarative SQL statements which can be stored in the database catalogue. A procedure can be thought of as a function or a method. The... | [
{
"code": null,
"e": 52,
"s": 24,
"text": "\n21 Mar, 2018"
},
{
"code": null,
"e": 575,
"s": 52,
"text": "PL/SQL is a block-structured language that enables developers to combine the power of SQL with procedural statements.A stored procedure in PL/SQL is nothing but a series of d... |
Print all combinations of balanced parentheses | 13 Jun, 2022
Write a function to generate all possible n pairs of balanced parentheses.
Examples:
Input: n=1
Output: {}
Explanation: This the only sequence of balanced
parenthesis formed using 1 pair of balanced parenthesis.
Input : n=2
Output:
{}{}
{{}}
Explanation: This the only two sequences of balanced
paren... | [
{
"code": null,
"e": 52,
"s": 24,
"text": "\n13 Jun, 2022"
},
{
"code": null,
"e": 128,
"s": 52,
"text": "Write a function to generate all possible n pairs of balanced parentheses. "
},
{
"code": null,
"e": 139,
"s": 128,
"text": "Examples: "
},
{
"cod... |
Window functions in SQL | 29 Jun, 2022
Window functions applies aggregate and ranking functions over a particular window (set of rows). OVER clause is used with window functions to define that window. OVER clause does two things :
Partitions rows into form set of rows. (PARTITION BY clause is used)
Orders rows within those partitions into a p... | [
{
"code": null,
"e": 54,
"s": 26,
"text": "\n29 Jun, 2022"
},
{
"code": null,
"e": 247,
"s": 54,
"text": "Window functions applies aggregate and ranking functions over a particular window (set of rows). OVER clause is used with window functions to define that window. OVER clause ... |
SQL Query to Update Columns Values With Column of Another Table | 23 Sep, 2021
In SQL update belongs to DDL (Data definition language). Using the UPDATE command we can update the present data in the table using the necessary queries. In this article, we see how to update column values with column values of another table using MSSQL as a server.
Syntax: For update query
UPDATE table_n... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n23 Sep, 2021"
},
{
"code": null,
"e": 296,
"s": 28,
"text": "In SQL update belongs to DDL (Data definition language). Using the UPDATE command we can update the present data in the table using the necessary queries. In this article, we ... |
Twisted Prime Number | 16 Mar, 2022
A number is said to be twisted prime if it is a prime number and reverse of the number is also a prime number.Examples:
Input : 97
Output : Twisted Prime Number
Explanation: 97 is a prime number
and its reverse 79 is also a prime
number.
Input : 43
Output : Not a Twisted Prime Number
Explanation: 43 is ... | [
{
"code": null,
"e": 52,
"s": 24,
"text": "\n16 Mar, 2022"
},
{
"code": null,
"e": 174,
"s": 52,
"text": "A number is said to be twisted prime if it is a prime number and reverse of the number is also a prime number.Examples: "
},
{
"code": null,
"e": 416,
"s": 1... |
Reading rpt files with Pandas | 16 May, 2021
In most cases, we usually have a CSV file to load the data from, but there are other formats such as JSON, rpt, TSV, etc. that can be used to store data. Pandas provide us with the utility to load data from them. In this article, we’ll see how we can load data from an rpt file with the use of Pandas.
An RP... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n16 May, 2021"
},
{
"code": null,
"e": 330,
"s": 28,
"text": "In most cases, we usually have a CSV file to load the data from, but there are other formats such as JSON, rpt, TSV, etc. that can be used to store data. Pandas provide us wit... |
Quantile and Decile rank of a column in Pandas-Python | 10 Jul, 2020
Let’s see how to find the Quantile and Decile ranks of a column in Pandas. We will be using the qcut() function of the pandas module.
Pandas library’s function qcut() is a Quantile-based discretization function. This means that it discretize the variables into equal-sized buckets based on rank or based on ... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n10 Jul, 2020"
},
{
"code": null,
"e": 162,
"s": 28,
"text": "Let’s see how to find the Quantile and Decile ranks of a column in Pandas. We will be using the qcut() function of the pandas module."
},
{
"code": null,
"e": 353,... |
MoviePy – Saving a Frame of Video Clip | 01 Aug, 2020
In this article we will see how we can save a single frame at given time of the video file clip in MoviePy. MoviePy is a Python module for video editing, which can be used for basic operations on videos and GIF’s. Video is formed by the frames, combination of frames creates a video each frame is an individ... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n01 Aug, 2020"
},
{
"code": null,
"e": 391,
"s": 28,
"text": "In this article we will see how we can save a single frame at given time of the video file clip in MoviePy. MoviePy is a Python module for video editing, which can be used for... |
How to draw color filled star in Python-Turtle? | 08 Oct, 2020
Prerequisite: Turtle Programming Basics, Draw Color Filled Shapes in Turtle
Turtle is an inbuilt module in Python. It provides drawing using a screen (cardboard) and turtle (pen). To draw something on the screen, we need to move the turtle (pen). To move the turtle, there are some functions i.e forward(), ... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n08 Oct, 2020"
},
{
"code": null,
"e": 104,
"s": 28,
"text": "Prerequisite: Turtle Programming Basics, Draw Color Filled Shapes in Turtle"
},
{
"code": null,
"e": 353,
"s": 104,
"text": "Turtle is an inbuilt module in... |
Permutation and Combination in Python? | In this section, we are going to learn how to find permutation and combination of a given sequence using python programming language.
One of the key advantage of python over other programming language is that it comes with huge set of libraries with it.
We are going to use python inbuilt package to find permutation and... | [
{
"code": null,
"e": 1321,
"s": 1187,
"text": "In this section, we are going to learn how to find permutation and combination of a given sequence using python programming language."
},
{
"code": null,
"e": 1441,
"s": 1321,
"text": "One of the key advantage of python over other pr... |
jMeter - Interview Questions | Dear readers, these JMeter Interview Questions have been designed specially to get you acquainted with the nature of questions you may encounter during your interview for the subject of JMeter. As per my experience good interviewers hardly plan to ask any particular question during your interview, normally questions s... | [
{
"code": null,
"e": 2476,
"s": 2039,
"text": "Dear readers, these JMeter Interview Questions have been designed specially to get you acquainted with the nature of questions you may encounter during your interview for the subject of JMeter. As per my experience good interviewers hardly plan to ask ... |
Find first node of loop in a linked list | 22 Jun, 2022
Write a function findFirstLoopNode() that checks whether a given Linked List contains a loop. If the loop is present then it returns point to the first node of the loop. Else it returns NULL.
Example :
Input : Head of below linked list
Output : Pointer to node 2
We have discussed Floyd’s loop detection al... | [
{
"code": null,
"e": 54,
"s": 26,
"text": "\n22 Jun, 2022"
},
{
"code": null,
"e": 246,
"s": 54,
"text": "Write a function findFirstLoopNode() that checks whether a given Linked List contains a loop. If the loop is present then it returns point to the first node of the loop. Else... |
Python | Sort lists in tuple | 14 May, 2020
Sometimes, while working with Python tuples, we can have a problem in which we need to sort the tuples which constitutes of lists and we need to sort each of them. Let’s discuss certain ways in which this task can be performed.
Method #1 : Using tuple() + sorted() + generator expressionThis task can be per... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n14 May, 2020"
},
{
"code": null,
"e": 256,
"s": 28,
"text": "Sometimes, while working with Python tuples, we can have a problem in which we need to sort the tuples which constitutes of lists and we need to sort each of them. Let’s discu... |
Feature matching using ORB algorithm in Python-OpenCV - GeeksforGeeks | 04 Oct, 2021
ORB is a fusion of FAST keypoint detector and BRIEF descriptor with some added features to improve the performance. FAST is Features from Accelerated Segment Test used to detect features from the provided image. It also uses a pyramid to produce multiscale-features. Now it doesn’t compute the orientation a... | [
{
"code": null,
"e": 24424,
"s": 24396,
"text": "\n04 Oct, 2021"
},
{
"code": null,
"e": 24806,
"s": 24424,
"text": "ORB is a fusion of FAST keypoint detector and BRIEF descriptor with some added features to improve the performance. FAST is Features from Accelerated Segment Test ... |
Forecasting Business KPIs With Python Using Prophet-Part 1 | by AnBento | Towards Data Science | Update: Many of you contacted me asking for valuable resources to learn more about time series forecasting with Python. Below I share 2 courses that I personally took and that would strongly recommend to expand your knowledge on the topic:
Python For Time Series Analysis (using ARIMA, SARIMAX, VARMA, PROPHET) 15+ hours... | [
{
"code": null,
"e": 411,
"s": 171,
"text": "Update: Many of you contacted me asking for valuable resources to learn more about time series forecasting with Python. Below I share 2 courses that I personally took and that would strongly recommend to expand your knowledge on the topic:"
},
{
"... |
Encoders and Decoders in Digital Logic - GeeksforGeeks | 25 Nov, 2019
Prerequisite – Encoder, Decoders
Binary code of N digits can be used to store 2N distinct elements of coded information. This is what encoders and decoders are used for. Encoders convert 2N lines of input into a code of N bits and Decoders decode the N bits into 2N lines.
1. Encoders –An encoder is a combi... | [
{
"code": null,
"e": 26754,
"s": 26726,
"text": "\n25 Nov, 2019"
},
{
"code": null,
"e": 26787,
"s": 26754,
"text": "Prerequisite – Encoder, Decoders"
},
{
"code": null,
"e": 27027,
"s": 26787,
"text": "Binary code of N digits can be used to store 2N distinct ... |
Create a Circular Progress Bar using HTML and CSS - GeeksforGeeks | 24 Jun, 2021
A progress bar is used to display the progress of a process on a computer. A progress bar displays how much of the process is completed and how much is left. So, today we will design a circular progress bar using HTML and CSS. By using HTML, we will design the different components for that progress bar and... | [
{
"code": null,
"e": 24316,
"s": 24288,
"text": "\n24 Jun, 2021"
},
{
"code": null,
"e": 24692,
"s": 24316,
"text": "A progress bar is used to display the progress of a process on a computer. A progress bar displays how much of the process is completed and how much is left. So, t... |
Batch Script - HELP | This batch command shows the list of Windows-supplied commands.
help
@echo off
help
The above command will display a list of all commands and their description. Following is an example of a subset of the output.
SCHTASKS Schedules commands and programs to run on a computer.
SHIFT Shifts the position of repl... | [
{
"code": null,
"e": 2233,
"s": 2169,
"text": "This batch command shows the list of Windows-supplied commands."
},
{
"code": null,
"e": 2239,
"s": 2233,
"text": "help\n"
},
{
"code": null,
"e": 2255,
"s": 2239,
"text": "@echo off \nhelp"
},
{
"code": n... |
How to import csv file in PHP? | The below code can be used to import CSV file in PHP −
<?php
$row = 1;
if (($handle = fopen("name_of_file.csv", "r")) !== FALSE) {
while (($data = fgetcsv($handle, 1000, ",")) !== FALSE) {
$num = count($data);
echo "<p> $num fields in line $row: <br /></p>\n";
$row++;
for ($c=0; $c < $num; $c... | [
{
"code": null,
"e": 1117,
"s": 1062,
"text": "The below code can be used to import CSV file in PHP −"
},
{
"code": null,
"e": 1464,
"s": 1117,
"text": "<?php\n$row = 1;\nif (($handle = fopen(\"name_of_file.csv\", \"r\")) !== FALSE) {\n while (($data = fgetcsv($handle, 1000, \"... |
How to convert date to another timezone in JavaScript ? | 22 Jun, 2020
Method 1: Using Intl.DateTimeFormat() and format() Method: The Intl.NumberFormat() method is used to represent numbers in a language-sensitive formatting. It can be used to represent currency or percentages according to the locale specified.The format() method of this object is used to return a string of t... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n22 Jun, 2020"
},
{
"code": null,
"e": 489,
"s": 28,
"text": "Method 1: Using Intl.DateTimeFormat() and format() Method: The Intl.NumberFormat() method is used to represent numbers in a language-sensitive formatting. It can be used to re... |
How to traceroute using PowerShell? | Traceroute is the way to determine the hopes that the packets are passing through when requested. In the command prompt, that utility is called the tracert and we can also use that utility to trace the network packets. For example,
PS C:\> tracert google.com
Tracing route to google.com [216.58.203.142]
over a maximum o... | [
{
"code": null,
"e": 1419,
"s": 1187,
"text": "Traceroute is the way to determine the hopes that the packets are passing through when requested. In the command prompt, that utility is called the tracert and we can also use that utility to trace the network packets. For example,"
},
{
"code":... |
Spring MVC - Dropdown Example | The following example describes how to use Dropdown in forms using the Spring Web MVC framework. To start with, let us have a working Eclipse IDE in place and stick to the following steps to develop a Dynamic Form based Web Application using the Spring Web Framework.
package com.tutorialspoint;
public class User {
... | [
{
"code": null,
"e": 3193,
"s": 2925,
"text": "The following example describes how to use Dropdown in forms using the Spring Web MVC framework. To start with, let us have a working Eclipse IDE in place and stick to the following steps to develop a Dynamic Form based Web Application using the Spring ... |
Need of Concurrent Collections in java | 08 Jan, 2018
As we already know Collections which is nothing but collections of Objects where we deals with the Objects using some pre-defined methods. But There are several problems which occurs when we use Collections concept in multi-threading. The problems which occurs while using Collections in Multi-threaded appl... | [
{
"code": null,
"e": 53,
"s": 25,
"text": "\n08 Jan, 2018"
},
{
"code": null,
"e": 369,
"s": 53,
"text": "As we already know Collections which is nothing but collections of Objects where we deals with the Objects using some pre-defined methods. But There are several problems whic... |
How to modify the size of column in MySQL table? | We can modify a column size with the help of ALTER command. Let us see how to modify
column size. Suppose we are defining any column with some size. At the time of inserting if we
are giving more size in comparison to the one we defined, then an error will generate.
The above problem can be reduced while modifying the ... | [
{
"code": null,
"e": 1454,
"s": 1187,
"text": "We can modify a column size with the help of ALTER command. Let us see how to modify\ncolumn size. Suppose we are defining any column with some size. At the time of inserting if we\nare giving more size in comparison to the one we defined, then an error... |
How to Add Edit and Delete Table Row in jQuery ? | 23 Jun, 2022
In this article, we will create an example of how to add, edit and delete table rows in jQuery. For creating this functionality we need to know about the basics of the HTML table, jQuery basic functionality.
Table row: An HTML table is a combination of rows and columns. The table row is in the horizontal ... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n23 Jun, 2022"
},
{
"code": null,
"e": 237,
"s": 28,
"text": "In this article, we will create an example of how to add, edit and delete table rows in jQuery. For creating this functionality we need to know about the basics of the HTML ta... |
How to Implement Custom Dialog Maker in Android? | 15 Nov, 2021
In this article, we are going to make an application of Custom Dialog Maker in android studio. In this application, we can create dialogs of our own choice of style, type, and animation.
A dialog is a small window that prompts the user to make a decision, provide some additional information, and inform the... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n15 Nov, 2021"
},
{
"code": null,
"e": 215,
"s": 28,
"text": "In this article, we are going to make an application of Custom Dialog Maker in android studio. In this application, we can create dialogs of our own choice of style, type, and... |
HTML <canvas> Tag | 17 Mar, 2022
The <canvas> tag in HTML is used to draw graphics on a web page using JavaScript. It can be used to draw paths, boxes, texts, gradients, and adding images. By default, it does not contain borders and text.
Note: The <canvas> tag is new in HTML5.
Syntax:
<canvas id = "script"> Contents... </canvas>
Attrib... | [
{
"code": null,
"e": 53,
"s": 25,
"text": "\n17 Mar, 2022"
},
{
"code": null,
"e": 260,
"s": 53,
"text": "The <canvas> tag in HTML is used to draw graphics on a web page using JavaScript. It can be used to draw paths, boxes, texts, gradients, and adding images. By default, it doe... |
Java.util.LinkedList.peek() , peekfirst(), peeklast() in Java | 10 Dec, 2018
Linked list class offers the functionality to “look into” the first and last elements of the list and hence can be useful in cases where only the retrieval is required and not necessarily the deletion is required. Three functionalities are present and all are discussed in this article. 1. peek() : This met... | [
{
"code": null,
"e": 53,
"s": 25,
"text": "\n10 Dec, 2018"
},
{
"code": null,
"e": 435,
"s": 53,
"text": "Linked list class offers the functionality to “look into” the first and last elements of the list and hence can be useful in cases where only the retrieval is required and no... |
JavaScript String indexOf() Method | 05 Oct, 2021
Below is the example of the String indexOf() Method.
Example:
JavaScript
// JavaScript to illustrate indexOf() function<script>function func() { // Original string var str = 'Departed Train'; // Finding index of occurrence of 'Train' var index = str.indexOf('Train'); document.write(index... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n05 Oct, 2021"
},
{
"code": null,
"e": 83,
"s": 28,
"text": "Below is the example of the String indexOf() Method. "
},
{
"code": null,
"e": 92,
"s": 83,
"text": "Example:"
},
{
"code": null,
"e": 103,
... |
What is ‘this’ reference in Java? | The this is a keyword in Java which is used as a reference to the object of the current class, with in an instance method or a constructor. Using this you can refer the members of a class such as constructors, variables and methods.
Using “this” you can −
Differentiate the instance variables from local variables if the... | [
{
"code": null,
"e": 1420,
"s": 1187,
"text": "The this is a keyword in Java which is used as a reference to the object of the current class, with in an instance method or a constructor. Using this you can refer the members of a class such as constructors, variables and methods."
},
{
"code"... |
whatis command in Linux with Examples | 27 May, 2019
whatis command in Linux is used to get a one-line manual page descriptions. In Linux, each manual page has some sort of description within it. So this command search for the manual pages names and show the manual page description of the specified filename or argument.
Syntax:
whatis [-dlv?V] [-r|-w] [-s li... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n27 May, 2019"
},
{
"code": null,
"e": 297,
"s": 28,
"text": "whatis command in Linux is used to get a one-line manual page descriptions. In Linux, each manual page has some sort of description within it. So this command search for the m... |
How to make the images bigger when clicked? | 18 May, 2022
There are two commonly used methods which can be used to resize an image when clicked using javascript. The javascript functions can be invoked by specifying the onclick=”function_name()”
Method 1: transform : scale()
Syntax:
object.style.transform = scale(sx);
object.style.transform = scale(sx, sy);
The ... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n18 May, 2022"
},
{
"code": null,
"e": 216,
"s": 28,
"text": "There are two commonly used methods which can be used to resize an image when clicked using javascript. The javascript functions can be invoked by specifying the onclick=”func... |
How to Convert Data URI to File then append to FormData? | 07 May, 2020
A data URI is a base64 encoded string that represents a file (i.e., instead of specifying the URL of the file, you can insert the content of the file in a webpage). When a browser encounters a URI, it decodes and constructs the original file. DataURIs are most commonly used on the web for images. When a we... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n07 May, 2020"
},
{
"code": null,
"e": 527,
"s": 28,
"text": "A data URI is a base64 encoded string that represents a file (i.e., instead of specifying the URL of the file, you can insert the content of the file in a webpage). When a bro... |
Find the word from a given sentence having given word as prefix | 24 May, 2021
Given a string S representing a sentence and another string word, the task is to find the word from S which has the string word as a prefix. If no such word is present in the string, print -1.
Examples:
Input: S = “Welcome to Geeksforgeeks”, word=”Gee”Output: GeeksforgeeksExplanation:The word “Geeksforgeek... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n24 May, 2021"
},
{
"code": null,
"e": 221,
"s": 28,
"text": "Given a string S representing a sentence and another string word, the task is to find the word from S which has the string word as a prefix. If no such word is present in the ... |
Length of longest palindrome list in a linked list using O(1) extra space | 07 Jul, 2022
Given a linked list, find the length of the longest palindrome list that exists in that linked list.
Examples:
Input : List = 2->3->7->3->2->12->24
Output : 5
The longest palindrome list is 2->3->7->3->2
Input : List = 12->4->4->3->14
Output : 2
The longest palindrome list is 4->4
A simple solution co... | [
{
"code": null,
"e": 52,
"s": 24,
"text": "\n07 Jul, 2022"
},
{
"code": null,
"e": 154,
"s": 52,
"text": "Given a linked list, find the length of the longest palindrome list that exists in that linked list. "
},
{
"code": null,
"e": 165,
"s": 154,
"text": "Exa... |
Python - Get a sorted list of random integers with unique elements - GeeksforGeeks | 11 May, 2020
Given lower and upper limits, generate a sorted list of random numbers with unique elements, starting from start to end.
Examples:
Input: num = 10, start = 100, end = 200
Output: [102, 118, 124, 131, 140, 148, 161, 166, 176, 180]
Input: num = 5, start = 1, end = 100
Output: [37, 49, 64, 84, 95]
To genera... | [
{
"code": null,
"e": 25010,
"s": 24982,
"text": "\n11 May, 2020"
},
{
"code": null,
"e": 25131,
"s": 25010,
"text": "Given lower and upper limits, generate a sorted list of random numbers with unique elements, starting from start to end."
},
{
"code": null,
"e": 25141... |
Exponential Distribution — Intuition, Derivation, and Applications | by Aerin Kim | Towards Data Science | We always start with the “why” instead of going straight to the formulas. If you understand the why, it actually sticks with you and you’ll be a lot more likely to apply it in your own line of work.
To predict the amount of waiting time until the next event (i.e., success, failure, arrival, etc.).
For example, we want ... | [
{
"code": null,
"e": 245,
"s": 46,
"text": "We always start with the “why” instead of going straight to the formulas. If you understand the why, it actually sticks with you and you’ll be a lot more likely to apply it in your own line of work."
},
{
"code": null,
"e": 345,
"s": 245,
... |
Linear gradient with rainbow color | To create a linear gradient that looks like rainbow color, you can try to run the following code\
Live Demo
<!DOCTYPE html>
<html>
<head>
<style>
#demo {
height: 100px;
background: linear-gradient(to right, red,orange,yellow,green,blue,indigo,violet);
}
</style>
... | [
{
"code": null,
"e": 1160,
"s": 1062,
"text": "To create a linear gradient that looks like rainbow color, you can try to run the following code\\"
},
{
"code": null,
"e": 1170,
"s": 1160,
"text": "Live Demo"
},
{
"code": null,
"e": 1494,
"s": 1170,
"text": "<!... |
Difference between an Integer and int in Java | A Java both int and Integer are used to store integer type data the major difference between both is type of int is primitive while Integer is of class type.This difference become significant when concept of OOPs comes in picture during development as int follows the principle of primitive data type while Integer behav... | [
{
"code": null,
"e": 1404,
"s": 1062,
"text": "A Java both int and Integer are used to store integer type data the major difference between both is type of int is primitive while Integer is of class type.This difference become significant when concept of OOPs comes in picture during development as i... |
How to define a MIN and MAX value for EditText in Android using Kotlin? | This example demonstrates how to define a MIN and MAX value for EditText 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=... | [
{
"code": null,
"e": 1159,
"s": 1062,
"text": "This example demonstrates how to define a MIN and MAX value for EditText in Android using Kotlin"
},
{
"code": null,
"e": 1288,
"s": 1159,
"text": "Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill al... |
Setting null values with an HTML <select> using AngularJS. | To set null values, here is the controller −
function display($scope) {
$scope.obj ={"selected":null};
$scope.objects = [{id: 1, value: "Yes"}, {id: 0, value: "No"}]
}
The following is the template −
<div ng-controller = "display">
<select ng-model = "obj.selected"
ng-options = "value.id as value.value f... | [
{
"code": null,
"e": 1107,
"s": 1062,
"text": "To set null values, here is the controller −"
},
{
"code": null,
"e": 1236,
"s": 1107,
"text": "function display($scope) {\n $scope.obj ={\"selected\":null};\n $scope.objects = [{id: 1, value: \"Yes\"}, {id: 0, value: \"No\"}]\n}... |
Python 3 - IF Statement | The IF statement is similar to that of other languages. The if statement contains a logical expression using which the data is compared and a decision is made based on the result of the comparison.
if expression:
statement(s)
If the boolean expression evaluates to TRUE, then the block of statement(s) inside the if ... | [
{
"code": null,
"e": 2538,
"s": 2340,
"text": "The IF statement is similar to that of other languages. The if statement contains a logical expression using which the data is compared and a decision is made based on the result of the comparison."
},
{
"code": null,
"e": 2570,
"s": 253... |
Get the last day of month in Java | The getActualMaximum() method returns the maximum value that the specified calendar field could have, based on the time value of this Calendar.
Import the following package to work with Calendar class in Java,
import java.util.Calendar;
Create a calendar object.
Calendar cal = Calendar.getInstance();
Use the getActualM... | [
{
"code": null,
"e": 1206,
"s": 1062,
"text": "The getActualMaximum() method returns the maximum value that the specified calendar field could have, based on the time value of this Calendar."
},
{
"code": null,
"e": 1272,
"s": 1206,
"text": "Import the following package to work w... |
How to Select single column of a Pandas Dataframe? - GeeksforGeeks | 01 Oct, 2020
In this article, we will discuss how to select a single column in a data frame. Now let us try to implement this using Python.
First, let’s create a dataframe
Python3
# importing pandas as libraryimport pandas as pd # creating data frame:df = pd.DataFrame({'name': ['Akash', 'Ayush', 'Ashish', ... | [
{
"code": null,
"e": 24212,
"s": 24184,
"text": "\n01 Oct, 2020"
},
{
"code": null,
"e": 24339,
"s": 24212,
"text": "In this article, we will discuss how to select a single column in a data frame. Now let us try to implement this using Python."
},
{
"code": null,
"e":... |
How to display a directory list in HTML? | Use the dir tag in HTML to display directory list. This is very similar to <ul> tag but do not use <dir> since it is deprecated now.
The following is the attribute −
You can try to run the following code to show a directory list in HTML −
<!DOCTYPE html>
<html>
<head>
<title>HTML dir Tag</title>
</head>
... | [
{
"code": null,
"e": 1195,
"s": 1062,
"text": "Use the dir tag in HTML to display directory list. This is very similar to <ul> tag but do not use <dir> since it is deprecated now."
},
{
"code": null,
"e": 1228,
"s": 1195,
"text": "The following is the attribute −"
},
{
"c... |
Double.CompareTo Method in C# with Examples | The Double.CompareTo() method in C# is used to compare this instance to a specified object or Double object and returns an integer that indicates whether the value of this instance is less than, equal to, or greater than the value of the specified object or Double object.
The syntax is as follows −
public int CompareTo... | [
{
"code": null,
"e": 1335,
"s": 1062,
"text": "The Double.CompareTo() method in C# is used to compare this instance to a specified object or Double object and returns an integer that indicates whether the value of this instance is less than, equal to, or greater than the value of the specified objec... |
How to draw a line on a Tkinter canvas? | Tkinter Canvas widget can be used for multiple purposes such as drawing shapes, objects, creating graphics and images. To draw a line on a Canvas, we can use create_line(x,y,x1,y1, **options) method.
In Tkinter, we can draw two types of lines: simple and dashed. We can specify the type of line using the dash property.
... | [
{
"code": null,
"e": 1262,
"s": 1062,
"text": "Tkinter Canvas widget can be used for multiple purposes such as drawing shapes, objects, creating graphics and images. To draw a line on a Canvas, we can use create_line(x,y,x1,y1, **options) method."
},
{
"code": null,
"e": 1382,
"s": 1... |
How to Create a Photo Mosaic in Python | by Bilal Himite | Towards Data Science | While many online websites can generate photo mosaics, in this article we will look under the hood of photomosaics and create a Python script that can create them.
A mosaic is a pattern made from small colored pieces held in place by mortar. They are usually used as decoration on walls or floors.
A photo mosaic on the ... | [
{
"code": null,
"e": 335,
"s": 171,
"text": "While many online websites can generate photo mosaics, in this article we will look under the hood of photomosaics and create a Python script that can create them."
},
{
"code": null,
"e": 469,
"s": 335,
"text": "A mosaic is a pattern ... |
Given a Boolean Matrix, find k such that all elements in k'th row are 0 and k'th column are 1. - GeeksforGeeks | 20 Jan, 2022
Given a square boolean matrix mat[n][n], find k such that all elements in k’th row are 0 and all elements in k’th column are 1. The value of mat[k][k] can be anything (either 0 or 1). If no such k exists, return -1.Examples:
Input: bool mat[n][n] = { {1, 0, 0, 0},
{1, 1, 1, 0},
... | [
{
"code": null,
"e": 24840,
"s": 24812,
"text": "\n20 Jan, 2022"
},
{
"code": null,
"e": 25067,
"s": 24840,
"text": "Given a square boolean matrix mat[n][n], find k such that all elements in k’th row are 0 and all elements in k’th column are 1. The value of mat[k][k] can be anyth... |
Ruby | Array delete_at() operation - GeeksforGeeks | 31 Jul, 2021
Array#delete_at() : delete_at() is a Array class method which deletes the arrays elements at the mentioned index.
Syntax: Array.delete_at()
Parameter: index - value at specific index value to delete
Return: deleted element, nil - if the index value is out of range
Code #1 : Example for delete_at() me... | [
{
"code": null,
"e": 25327,
"s": 25299,
"text": "\n31 Jul, 2021"
},
{
"code": null,
"e": 25442,
"s": 25327,
"text": "Array#delete_at() : delete_at() is a Array class method which deletes the arrays elements at the mentioned index. "
},
{
"code": null,
"e": 25598,
... |
Python | Unpacking nested tuples - GeeksforGeeks | 17 Sep, 2019
Sometimes, while working with Python list of tuples, we can have a problem in which we require to unpack the packed tuples. This can have a possible application in web development. Let’s discuss certain ways in which this task can be performed.
Method #1 : Using list comprehensionThis task can be performed... | [
{
"code": null,
"e": 25521,
"s": 25493,
"text": "\n17 Sep, 2019"
},
{
"code": null,
"e": 25766,
"s": 25521,
"text": "Sometimes, while working with Python list of tuples, we can have a problem in which we require to unpack the packed tuples. This can have a possible application in... |
Calculator using PySimpleGUI - Python - GeeksforGeeks | 24 Feb, 2021
Prerequisite: PySimpleGUI, eval
PySimpleGUI is a Python package that enables Python programmers of all levels to create GUIs. You specify your GUI window using a “layout” that contains widgets (they’re called “Elements” in PySimpleGUI). In this article, we will learn, how to make a calculator using PySimpl... | [
{
"code": null,
"e": 23925,
"s": 23897,
"text": "\n24 Feb, 2021"
},
{
"code": null,
"e": 23957,
"s": 23925,
"text": "Prerequisite: PySimpleGUI, eval"
},
{
"code": null,
"e": 24248,
"s": 23957,
"text": "PySimpleGUI is a Python package that enables Python progra... |
Logistic Regression in Python - Restructuring Data | Whenever any organization conducts a survey, they try to collect as much information as possible from the customer, with the idea that this information would be useful to the organization one way or the other, at a later point of time. To solve the current problem, we have to pick up the information that is directly re... | [
{
"code": null,
"e": 2076,
"s": 1733,
"text": "Whenever any organization conducts a survey, they try to collect as much information as possible from the customer, with the idea that this information would be useful to the organization one way or the other, at a later point of time. To solve the curr... |
How do add dependency in Android studio | This example demonstrates about How to add dependency in Android studio
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"?>
<LinearLayout x... | [
{
"code": null,
"e": 1134,
"s": 1062,
"text": "This example demonstrates about How to add dependency in Android studio"
},
{
"code": null,
"e": 1263,
"s": 1134,
"text": "Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required details to cre... |
How to convert Boolean to String in JavaScript? | You can try to run the following to learn how to convert Boolean to String in JavaScript −
Live Demo
<!DOCTYPE html>
<html>
<body>
<p>Convert Boolean to String</p>
<script>
var myBool = false;
document.write("<br>String : " + String(myBool));
</script>
</body>
</html> | [
{
"code": null,
"e": 1153,
"s": 1062,
"text": "You can try to run the following to learn how to convert Boolean to String in JavaScript −"
},
{
"code": null,
"e": 1163,
"s": 1153,
"text": "Live Demo"
},
{
"code": null,
"e": 1373,
"s": 1163,
"text": "<!DOCTYPE ... |
Convert a string representation of list into list in Python | As python handles various data types, we will come across a situation where a list will appear in form of a string. In this article we will see how to convert a string into a list.
We first apply the strip method to remove the square brackets and then apply the split function. The split function with a comma as its par... | [
{
"code": null,
"e": 1243,
"s": 1062,
"text": "As python handles various data types, we will come across a situation where a list will appear in form of a string. In this article we will see how to convert a string into a list."
},
{
"code": null,
"e": 1422,
"s": 1243,
"text": "W... |
Delete first and last element from a LinkedList in Java | The first element can be deleted from a LinkedList by using the method java.util.LinkedList.removeFirst(). This method does not have any parameters and it returns the first element of the LinkedList.
The last element can be deleted from a LinkedList by using the method java.util.LinkedList.removeLast(). This method doe... | [
{
"code": null,
"e": 1262,
"s": 1062,
"text": "The first element can be deleted from a LinkedList by using the method java.util.LinkedList.removeFirst(). This method does not have any parameters and it returns the first element of the LinkedList."
},
{
"code": null,
"e": 1459,
"s": 1... |
Multivariate Logistic Regression in Python | by Sowmya Krishnan | Towards Data Science | You probably use machine learning dozens of times a day without even knowing it. A simple web search on Google works so well because the ML software behind it has learnt to figure out which pages to be ranked and how. Similarly, you are saved from wading through a ton of spam in your email because your computer has lea... | [
{
"code": null,
"e": 543,
"s": 171,
"text": "You probably use machine learning dozens of times a day without even knowing it. A simple web search on Google works so well because the ML software behind it has learnt to figure out which pages to be ranked and how. Similarly, you are saved from wading ... |
How to style images with CSS? | To style images with CSS, you need to use properties such as height, width, - moz-opacity, etc. Let us see how to create a transparent image with - moz-opacity CSS property:
The -moz-opacity property of an image is used to set the opacity of an image. This property is used to create a transparent image in Mozilla. IE u... | [
{
"code": null,
"e": 1236,
"s": 1062,
"text": "To style images with CSS, you need to use properties such as height, width, - moz-opacity, etc. Let us see how to create a transparent image with - moz-opacity CSS property:"
},
{
"code": null,
"e": 1440,
"s": 1236,
"text": "The -moz... |
GATE | GATE-CS-2009 | Question 43 - GeeksforGeeks | 06 Oct, 2021
Consider two transactions T1 and T2, and four schedules S1, S2, S3, S4 of T1 and T2 as given below:
T1 = R1[X] W1[X] W1[Y]
T2 = R2[X] R2[Y] W2[Y]
S1 = R1[X] R2[X] R2[Y] W1[X] W1[Y] W2[Y]
S2 = R1[X] R2[X] R2[Y] W1[X] W2[Y] W1[Y]
S3 = R1[X] W1[X] R2[X] W1[Y] R2[Y] W2[Y]
S4 = R2[X] R2[Y] R1[X] W1[X] W1[Y] W2[... | [
{
"code": null,
"e": 24117,
"s": 24089,
"text": "\n06 Oct, 2021"
},
{
"code": null,
"e": 24217,
"s": 24117,
"text": "Consider two transactions T1 and T2, and four schedules S1, S2, S3, S4 of T1 and T2 as given below:"
},
{
"code": null,
"e": 24427,
"s": 24217,
... |
Jython - Using the Swing GUI library | One of the major features of Jython is its ability to use the Swing GUI library in JDK. The Standard Python distribution (often called as CPython) has the Tkinter GUI library shipped with it. Other GUI libraries like PyQt and WxPython are also available for use with it, but the swing library offers a platform independe... | [
{
"code": null,
"e": 2417,
"s": 2081,
"text": "One of the major features of Jython is its ability to use the Swing GUI library in JDK. The Standard Python distribution (often called as CPython) has the Tkinter GUI library shipped with it. Other GUI libraries like PyQt and WxPython are also available... |
Installing PySpark with JAVA 8 on ubuntu 18.04 | by Parijat Bhatt | Towards Data Science | After a struggle for a few hours, I finally installed java 8, spark and configured all the environment variables. I went through a lot of medium articles and StackOverflow answers but not one particular answer or post did solve my problems. So this is just a small effort of mine to put everything together.
My machine h... | [
{
"code": null,
"e": 480,
"s": 172,
"text": "After a struggle for a few hours, I finally installed java 8, spark and configured all the environment variables. I went through a lot of medium articles and StackOverflow answers but not one particular answer or post did solve my problems. So this is jus... |
C library function - fscanf() | The C library function int fscanf(FILE *stream, const char *format, ...) reads formatted input from a stream.
Following is the declaration for fscanf() function.
int fscanf(FILE *stream, const char *format, ...)
stream − This is the pointer to a FILE object that identifies the stream.
stream − This is the pointer to a ... | [
{
"code": null,
"e": 2117,
"s": 2007,
"text": "The C library function int fscanf(FILE *stream, const char *format, ...) reads formatted input from a stream."
},
{
"code": null,
"e": 2169,
"s": 2117,
"text": "Following is the declaration for fscanf() function."
},
{
"code"... |
Reduce Array Size to The Half in C++ | Suppose we have an array arr. We can choose a set of integers and remove all the occurrences of these integers in the array. We have to find the minimum size of the set so that at least half of the integers of the array are removed. So for example, if arr = [3,3,3,3,5,5,5,2,2,7], then the output will be 2. This is beca... | [
{
"code": null,
"e": 1711,
"s": 1062,
"text": "Suppose we have an array arr. We can choose a set of integers and remove all the occurrences of these integers in the array. We have to find the minimum size of the set so that at least half of the integers of the array are removed. So for example, if a... |
Python - Graph Data | CSGraph stands for Compressed Sparse Graph, which focuses on Fast graph algorithms based on sparse matrix representations.
To begin with, let us understand what a sparse graph is and how it helps in graph representations.
A graph is just a collection of nodes, which have links between them. Graphs can represent nearly ... | [
{
"code": null,
"e": 2652,
"s": 2529,
"text": "CSGraph stands for Compressed Sparse Graph, which focuses on Fast graph algorithms based on sparse matrix representations."
},
{
"code": null,
"e": 2751,
"s": 2652,
"text": "To begin with, let us understand what a sparse graph is and... |
Combining aggregate and non-aggregate values in SQL using Joins and Over clause - GeeksforGeeks | 31 Aug, 2021
Prerequisite – Aggregate functions in SQL, Joins in SQLAggregate functions perform a calculation on a set of values and return a single value. Now, consider an employee table EMP and a department table DEPT with following structure:
Table – EMPLOYEE TABLE
Table – DEPARTMENT TABLE
And the following results ... | [
{
"code": null,
"e": 23938,
"s": 23910,
"text": "\n31 Aug, 2021"
},
{
"code": null,
"e": 24171,
"s": 23938,
"text": "Prerequisite – Aggregate functions in SQL, Joins in SQLAggregate functions perform a calculation on a set of values and return a single value. Now, consider an emp... |
Extract a particular element from a nested array in MongoDB | Extract a particular element from a nested array with the help of dot(.) notation. Let us first create a collection with documents −
> db.extractParticularElementDemo.insertOne(
... {
... "_id" : 101,
... "StudentName" : "John",
... "StudentInformation" : [
... {
... "Age" : 21... | [
{
"code": null,
"e": 1195,
"s": 1062,
"text": "Extract a particular element from a nested array with the help of dot(.) notation. Let us first create a collection with documents −"
},
{
"code": null,
"e": 2086,
"s": 1195,
"text": "> db.extractParticularElementDemo.insertOne(\n...... |
How to move your Game Character Around in Pygame - GeeksforGeeks | 23 Aug, 2021
Prerequisites: Pygame
Pygame is a cross-platform set of Python modules designed for writing video games. It includes computer graphics and sound libraries designed to be used with the Python programming language. You can create different types of games using pygame including arcade games, platformer games,... | [
{
"code": null,
"e": 24318,
"s": 24290,
"text": "\n23 Aug, 2021"
},
{
"code": null,
"e": 24340,
"s": 24318,
"text": "Prerequisites: Pygame"
},
{
"code": null,
"e": 24641,
"s": 24340,
"text": "Pygame is a cross-platform set of Python modules designed for writin... |
Construct a Turing machine for L = {aibjck | i*j = k; i, j, k ≥ 1} - GeeksforGeeks | 18 Oct, 2021
Prerequisite – Turing Machine In a given language, L = {aibjck | i*j = k; i, j, k ≥ 1}, where every string of ‘a’, ‘b’ and ‘c’ has a certain number of a’s, then a certain number of b’s and then a certain number of c’s. The condition is that each of these 3 symbols should occur at least once. ‘a’ and ‘b’ ca... | [
{
"code": null,
"e": 29445,
"s": 29417,
"text": "\n18 Oct, 2021"
},
{
"code": null,
"e": 29922,
"s": 29445,
"text": "Prerequisite – Turing Machine In a given language, L = {aibjck | i*j = k; i, j, k ≥ 1}, where every string of ‘a’, ‘b’ and ‘c’ has a certain number of a’s, then a ... |
Apriori algorithm implementation using optimized approach with pandas | by Karan Kharecha | Towards Data Science | In Big Data, this algorithm is the basic one that is used to find frequent items. Although apriori algorithm is quite slow as it deals with large number of subsets when itemset is big. With more items and less support counts of item, it takes really long to figure out frequent items. Hence, optimisation can be done in ... | [
{
"code": null,
"e": 825,
"s": 171,
"text": "In Big Data, this algorithm is the basic one that is used to find frequent items. Although apriori algorithm is quite slow as it deals with large number of subsets when itemset is big. With more items and less support counts of item, it takes really long ... |
sbyte Keyword in C# | 22 Jun, 2020
Keywords are the words in a language that are used for some internal process or represent some predefined actions. SByte is a keyword that is used to declare a variable that can store a signed value between the range of -128 to +127. It is an alias of System.SByte.
SByte keyword occupies 1 byte (8 bits) in... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n22 Jun, 2020"
},
{
"code": null,
"e": 294,
"s": 28,
"text": "Keywords are the words in a language that are used for some internal process or represent some predefined actions. SByte is a keyword that is used to declare a variable that c... |
Priority queue of pairs in C++ with ordering by first and second element | 28 Jul, 2020
Priority Queue: Priority queue is the extension of the queue in which elements associated with priority and elements having higher priority is popped first.
Priority queue can contain elements with various data types such as integer, pair of integers, custom data type. But one thing is common that there is... | [
{
"code": null,
"e": 54,
"s": 26,
"text": "\n28 Jul, 2020"
},
{
"code": null,
"e": 211,
"s": 54,
"text": "Priority Queue: Priority queue is the extension of the queue in which elements associated with priority and elements having higher priority is popped first."
},
{
"co... |
Errors in C/C++ | 09 Jun, 2022
Error is an illegal operation performed by the user which results in abnormal working of the program. Programming errors often remain undetected until the program is compiled or executed. Some of the errors inhibit the program from getting compiled or executed. Thus errors should be removed before compilin... | [
{
"code": null,
"e": 52,
"s": 24,
"text": "\n09 Jun, 2022"
},
{
"code": null,
"e": 438,
"s": 52,
"text": "Error is an illegal operation performed by the user which results in abnormal working of the program. Programming errors often remain undetected until the program is compiled... |
plotly.express.scatter_3d() function in Python | 17 Jul, 2020
Plotly library of Python can be very useful for data visualization and understanding the data simply and easily. Plotly graph objects are a high-level interface to plotly which are easy to use.
This function is used to create a 3D scatter plot and can be used with pandas dataframes. Each row of dataframe i... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n17 Jul, 2020"
},
{
"code": null,
"e": 222,
"s": 28,
"text": "Plotly library of Python can be very useful for data visualization and understanding the data simply and easily. Plotly graph objects are a high-level interface to plotly whic... |
Describe z-index and how a stacking context is formed in CSS | 19 Sep, 2021
The stacking order describes the order in which HTML elements are positioned. By default, HTML elements are positioned in the following order:
Root element(<html>)
Non-positioned elements in the order they’re defined(elements with no position described i.e. static)
Positioned elements in the order they are... | [
{
"code": null,
"e": 28,
"s": 0,
"text": "\n19 Sep, 2021"
},
{
"code": null,
"e": 171,
"s": 28,
"text": "The stacking order describes the order in which HTML elements are positioned. By default, HTML elements are positioned in the following order:"
},
{
"code": null,
... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.