title
stringlengths
3
221
text
stringlengths
17
477k
parsed
listlengths
0
3.17k
Complex numbers in C++ | Set 1 - GeeksforGeeks
06 Jul, 2017 The complex library implements the complex class to contain complex numbers in cartesian form and several functions and overloads to operate with them. real() – It returns the real part of the complex number. imag() – It returns the imaginary part of the complex number.// Program illustrating the use of re...
[ { "code": null, "e": 26355, "s": 26327, "text": "\n06 Jul, 2017" }, { "code": null, "e": 26507, "s": 26355, "text": "The complex library implements the complex class to contain complex numbers in cartesian form and several functions and overloads to operate with them." }, { ...
Ccat – Colorize Cat Command Output command in Linux with Examples - GeeksforGeeks
23 Sep, 2021 ccat is a command-line tool for Linux and OSX, which is similar to the cat command in Linux. But the difference between cat and ccat is that the ccat shows the content of the file with the syntax highlighted. Currently, ccat supports the following programming languages. JavaScript Java Ruby Python Go C JSO...
[ { "code": null, "e": 25955, "s": 25927, "text": "\n23 Sep, 2021" }, { "code": null, "e": 26226, "s": 25955, "text": "ccat is a command-line tool for Linux and OSX, which is similar to the cat command in Linux. But the difference between cat and ccat is that the ccat shows the con...
Discover Your Next Favorite Restaurant — Exploration and Visualization on Yelp Dataset | by Dehao Zhang | Towards Data Science
You just came to this city for the first time in your life. It is lunchtime. You are trying to find a good local restaurant but unfortunately, you don’t know anyone in the area to get recommendations from. What do you do now? If you choose to go on Yelp and look for answers, you are not the only one. As a platform whic...
[ { "code": null, "e": 232, "s": 172, "text": "You just came to this city for the first time in your life." }, { "code": null, "e": 398, "s": 232, "text": "It is lunchtime. You are trying to find a good local restaurant but unfortunately, you don’t know anyone in the area to get re...
How to change status bar color to match app Android?
This example demonstrates how do I change the status bar color to match app 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"?> <R...
[ { "code": null, "e": 1147, "s": 1062, "text": "This example demonstrates how do I change the status bar color to match app Android." }, { "code": null, "e": 1276, "s": 1147, "text": "Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required d...
Python PostgreSQL - Create Database
You can create a database in PostgreSQL using the CREATE DATABASE statement. You can execute this statement in PostgreSQL shell prompt by specifying the name of the database to be created after the command. Following is the syntax of the CREATE DATABASE statement. CREATE DATABASE dbname; Following statement creates a ...
[ { "code": null, "e": 3412, "s": 3205, "text": "You can create a database in PostgreSQL using the CREATE DATABASE statement. You can execute this statement in PostgreSQL shell prompt by specifying the name of the database to be created after the command." }, { "code": null, "e": 3470, ...
Huffman Decoding | Practice | GeeksforGeeks
Given a encoded binary string and a Huffman MinHeap tree, your task is to complete the function decodeHuffmanData(), which decodes the binary encoded string and return the original string. Note: Each node of the min heap contains 2 data members, a character and an integer to denote its frequency. The character '$' is ...
[ { "code": null, "e": 416, "s": 226, "text": "Given a encoded binary string and a Huffman MinHeap tree, your task is to complete the function decodeHuffmanData(), which decodes the binary encoded string and return the original string. " }, { "code": null, "e": 639, "s": 416, "text...
Difference between Lossless and Lossy Join Decomposition - GeeksforGeeks
25 Aug, 2021 The process of breaking up of a relation into smaller subrelations is called Decomposition. Decomposition is required in DBMS to convert a relation into specific normal form which further reduces redundancy, anomalies, and inconsistency in the relation. There are mainly two types of decompositions in DBMS...
[ { "code": null, "e": 24328, "s": 24300, "text": "\n25 Aug, 2021" }, { "code": null, "e": 24583, "s": 24328, "text": "The process of breaking up of a relation into smaller subrelations is called Decomposition. Decomposition is required in DBMS to convert a relation into specific n...
How to create plots with beautiful animation using gganimate. | by Brian Mwangi. | Towards Data Science
Introduction. The most important thing about visualization is when it forces us to realize something we didn’t know. Visually appealing charts easily draw our attention. Animating data is like breathing life into dust, it’s an act of creation. How do you create appealing animations that are insightful? In this article,...
[ { "code": null, "e": 186, "s": 172, "text": "Introduction." }, { "code": null, "e": 476, "s": 186, "text": "The most important thing about visualization is when it forces us to realize something we didn’t know. Visually appealing charts easily draw our attention. Animating data i...
C# | Creating a read-only wrapper for List - GeeksforGeeks
27 Jan, 2019 List<T>.AsReadOnly Method is used to get a read-only ReadOnlyCollection<T> wrapper for the current collection. Syntax: public System.Collections.ObjectModel.ReadOnlyCollection<T> AsReadOnly (); Return Value: It returns an object that acts as a read-only wrapper around the current List<T>. Example: // C# co...
[ { "code": null, "e": 23994, "s": 23966, "text": "\n27 Jan, 2019" }, { "code": null, "e": 24105, "s": 23994, "text": "List<T>.AsReadOnly Method is used to get a read-only ReadOnlyCollection<T> wrapper for the current collection." }, { "code": null, "e": 24113, "s":...
Understanding Letter Value Plot and Boxenplot | Towards Data Science
On top of this, boxplots are not easy to understand for everybody. That’s why data scientists often earn reactions like this when presenting boxplots to other people in the business: But help is here! Boxenplots (or letter-value plots) are an advancement of boxplots, designed to visualize distributions more accurately....
[ { "code": null, "e": 355, "s": 172, "text": "On top of this, boxplots are not easy to understand for everybody. That’s why data scientists often earn reactions like this when presenting boxplots to other people in the business:" }, { "code": null, "e": 579, "s": 355, "text": "But...
destroy() method in Tkinter - Python
The destroy() method in Tkinter destroys a widget. It is useful in controlling the behavior of various widgets which depend on each other. Also when a process is complete by some user action we need to destroy the GUI components to free the memory as well as clear the screen. The destroy() method achieves all this. In ...
[ { "code": null, "e": 1379, "s": 1062, "text": "The destroy() method in Tkinter destroys a widget. It is useful in controlling the behavior of various widgets which depend on each other. Also when a process is complete by some user action we need to destroy the GUI components to free the memory as we...
fc-cache command in Linux with Examples - GeeksforGeeks
15 May, 2019 The fc-cache command in Linux scans the font directories and build font cache for applications which use fontconfig for their font handling. When no arguments are passed fc-cache scans each directory for font files readable by FreeType. A cache is created which contains properties of each font and the asso...
[ { "code": null, "e": 24012, "s": 23984, "text": "\n15 May, 2019" }, { "code": null, "e": 24431, "s": 24012, "text": "The fc-cache command in Linux scans the font directories and build font cache for applications which use fontconfig for their font handling. When no arguments are ...
How to get services based on start-type in PowerShell?
Below commands are useful to filter services based on their start types (Automatic, Manual or Disabled). To get the Automatic start-type service. These services are started automatically when the system starts. Get-Service | where{$_.StartType -eq "Automatic"} | Select Name, Starttype SystemEventsBroker Automa...
[ { "code": null, "e": 1167, "s": 1062, "text": "Below commands are useful to filter services based on their start types (Automatic, Manual or Disabled)." }, { "code": null, "e": 1273, "s": 1167, "text": "To get the Automatic start-type service. These services are started automatic...
Bash Brace Expansion In Linux with Examples - GeeksforGeeks
25 Jan, 2021 Brасe exраnsiоn is а wаy by whiсh аrbitrаry strings саn be generаted frоm the terminаl оr by using any bаsh sсriрt, it allows you to create multiple modified command-line arguments out of a single argument. The syntаx fоr brасe exраnsiоn соnsists оf either a sequenсe sрeсifiсаtiоn оr а cоmmа seраrаted list...
[ { "code": null, "e": 24406, "s": 24378, "text": "\n25 Jan, 2021" }, { "code": null, "e": 25032, "s": 24406, "text": "Brасe exраnsiоn is а wаy by whiсh аrbitrаry strings саn be generаted frоm the terminаl оr by using any bаsh sсriрt, it allows you to create multiple modified comma...
Basic Curve Fitting of Scientific Data with Python | by Naveen Venkatesan | Towards Data Science
In addition to plotting data points from our experiments, we must often fit them to a theoretical model to extract important parameters. This short article will serve as a guide on how to fit a set of points to a known model equation, which we will do using the scipy.optimize.curve_fit function. The basics of plotting ...
[ { "code": null, "e": 695, "s": 172, "text": "In addition to plotting data points from our experiments, we must often fit them to a theoretical model to extract important parameters. This short article will serve as a guide on how to fit a set of points to a known model equation, which we will do usi...
Check if a binary string has a 0 between 1s or not | Set 1 (General approach) - GeeksforGeeks
20 May, 2021 Given a string of 0 and 1, we need to check that the given string is valid or not. The given string is valid when there is no zero is present in between 1’s. For example, 1111, 0000111110, 1111000 are valid strings but 01010011, 01010, 101 are not. One approach to solving the problem is discussed here, oth...
[ { "code": null, "e": 24852, "s": 24824, "text": "\n20 May, 2021" }, { "code": null, "e": 25214, "s": 24852, "text": "Given a string of 0 and 1, we need to check that the given string is valid or not. The given string is valid when there is no zero is present in between 1’s. For e...
Prime Factor in C++ Program
Prime Factor is a prime number which is the factor of the given number. Factor of a number are the numbers that are multiplied to get the given number. Prime Factorisation is the process of recursively dividing the number with its prime factors to find all the prime factors of the number. Example : N = 120 Prime factor...
[ { "code": null, "e": 1134, "s": 1062, "text": "Prime Factor is a prime number which is the factor of the given number." }, { "code": null, "e": 1214, "s": 1134, "text": "Factor of a number are the numbers that are multiplied to get the given number." }, { "code": null, ...
N-ary Tree Level Order Traversal in C++
Suppose we have an n-ary tree, we have to return the level order traversal of its nodes' values. The Nary-Tree input serialization is represented in their level order traversal. Here each group of children is separated by the null value (See examples). So the following tree can be represented as [1,null,3,2,4,null,5,6]...
[ { "code": null, "e": 1383, "s": 1062, "text": "Suppose we have an n-ary tree, we have to return the level order traversal of its nodes' values. The Nary-Tree input serialization is represented in their level order traversal. Here each group of children is separated by the null value (See examples). ...
From JSON object to an array in JavaScript
We are required to create an array out of a JavaScript object, containing the values of all of the object's properties. For example, given this object − { "firstName": "John", "lastName": "Smith", "isAlive": "true", "a } We have to produce this array − const myarray = ['John', 'Smith', 'true', '25']; Theref...
[ { "code": null, "e": 1182, "s": 1062, "text": "We are required to create an array out of a JavaScript object, containing the values of all of the object's properties." }, { "code": null, "e": 1215, "s": 1182, "text": "For example, given this object −" }, { "code": null, ...
Reinforcement Learning frameworks | by Jordi TORRES.AI | Towards Data Science
Welcome to this 20th post that concludes the “Deep Reinforcement Learning Explained” series that presents a practical approach to getting started in the exciting world of Deep Reinforcement Learning. So far, in previous posts, we have been looking at a basic representation of the corpus of RL algorithms (although we ha...
[ { "code": null, "e": 372, "s": 172, "text": "Welcome to this 20th post that concludes the “Deep Reinforcement Learning Explained” series that presents a practical approach to getting started in the exciting world of Deep Reinforcement Learning." }, { "code": null, "e": 791, "s": 372,...
Understanding Python imports, __init__.py and pythonpath — once and for all | by Dr. Varshita Sher | Towards Data Science
By the end of the tutorial, this is the directory structure (for the Medium_Imports_Tutorial project) that you would be comfortable working with — in terms of importing any script(s) from one subdirectory into another (arrows in blue). Note: If you’d like to play along, here is the Github repo. Before we even begin, le...
[ { "code": null, "e": 467, "s": 171, "text": "By the end of the tutorial, this is the directory structure (for the Medium_Imports_Tutorial project) that you would be comfortable working with — in terms of importing any script(s) from one subdirectory into another (arrows in blue). Note: If you’d like...
Creating all possible unique permutations of a string in JavaScript
We are required to write a JavaScript function that takes in a string str. Our function should create all permutations of the input string and remove duplicates, if present. This means, we have to shuffle all letters from the input in all possible orders. Following is the code − Live Demo const str = 'aabb'; const per...
[ { "code": null, "e": 1318, "s": 1062, "text": "We are required to write a JavaScript function that takes in a string str. Our function should create all permutations of the input string and remove duplicates, if present. This means, we have to shuffle all letters from the input in all possible order...
Count positive and negative numbers in a list in Python program
In this article, we will learn about the solution to the problem statement given below. Problem statement − We are given a list iterable, we need to count positive and negative numbers in it and display them. Here we need to iterate each element in the list using a for loop and check whether num>=0, to filter the posit...
[ { "code": null, "e": 1150, "s": 1062, "text": "In this article, we will learn about the solution to the problem statement given below." }, { "code": null, "e": 1271, "s": 1150, "text": "Problem statement − We are given a list iterable, we need to count positive and negative numbe...
Count of strings that does not contain any character of a given string - GeeksforGeeks
23 Dec, 2021 Given an array arr containing N strings and a string str, the task is to find the number of strings that do not contain any character of string str. Examples: Input: arr[] = {“abcd”, “hijk”, “xyz”, “ayt”}, str=”apple”Output: 2Explanation: “hijk” and “xyz” are the strings that do not contain any character o...
[ { "code": null, "e": 24796, "s": 24768, "text": "\n23 Dec, 2021" }, { "code": null, "e": 24945, "s": 24796, "text": "Given an array arr containing N strings and a string str, the task is to find the number of strings that do not contain any character of string str." }, { ...
Standard Size of character ('a') in C/C++ on Linux
In C++ the size of the character literal is char. In C the type of character literal is integer (int). So in C the sizeof(‘a’) is 4 for 32bit architecture, and CHAR_BIT is 8. But the sizeof(char) is one byte for both C and C++. Live Demo #include<stdio.h> main() { printf("%d", sizeof('a')); } 1 Live Demo #include<...
[ { "code": null, "e": 1290, "s": 1062, "text": "In C++ the size of the character literal is char. In C the type of character literal is integer (int). So in C the sizeof(‘a’) is 4 for 32bit architecture, and CHAR_BIT is 8. But the sizeof(char) is one byte for both C and C++." }, { "code": nul...
Display specific table names with MySQL LIKE Operator
To display specific table names with LIKE operator, the syntax is as follows − select table_name as `anyAliasName` from information_schema.tables where table_name like ‘yourValue%'; Let us implement the above syntax to display specific table names with LIKE operator − mysql> select table_name as `DemoTable1600` ...
[ { "code": null, "e": 1141, "s": 1062, "text": "To display specific table names with LIKE operator, the syntax is as follows −" }, { "code": null, "e": 1248, "s": 1141, "text": "select table_name as `anyAliasName`\n from information_schema.tables\nwhere table_name like ‘yourVal...
GATE | GATE-CS-2006 | Question 44 - GeeksforGeeks
28 Jun, 2021 Station A uses 32 byte packets to transmit messages to Station B using a sliding window protocol. The round trip delay between A and B is 80 milliseconds and the bottleneck bandwidth on the path between A and B is 128 kbps. What is the optimal window size that A should use?(A) 20(B) 40(C) 160(D) 320Answer:...
[ { "code": null, "e": 24099, "s": 24071, "text": "\n28 Jun, 2021" }, { "code": null, "e": 24423, "s": 24099, "text": "Station A uses 32 byte packets to transmit messages to Station B using a sliding window protocol. The round trip delay between A and B is 80 milliseconds and the b...
JavaScript DOM CSS
The HTML DOM allows JavaScript to change the style of HTML elements. To change the style of an HTML element, use this syntax: The following example changes the style of a <p> element: The HTML DOM allows you to execute code when an event occurs. Events are generated by the browser when "things happen" to HTML elements:...
[ { "code": null, "e": 69, "s": 0, "text": "The HTML DOM allows JavaScript to change the style of HTML elements." }, { "code": null, "e": 126, "s": 69, "text": "To change the style of an HTML element, use this syntax:" }, { "code": null, "e": 184, "s": 126, "tex...
Java Program to remove the leading and trailing quotes from a string
Firstly, let us consider a string with quotes String originalStr = "\"Demo Text\""; Now, consider the following logic for the beginning quote. if (originalStr.startsWith("\"")) { originalStr = originalStr.substring(1, originalStr.length()); } Now, consider the following logic for the ending quote. if (originalStr.en...
[ { "code": null, "e": 1108, "s": 1062, "text": "Firstly, let us consider a string with quotes" }, { "code": null, "e": 1146, "s": 1108, "text": "String originalStr = \"\\\"Demo Text\\\"\";" }, { "code": null, "e": 1205, "s": 1146, "text": "Now, consider the fol...
Apriori Algorithm for Association Rule Learning — How To Find Clear Links Between Transactions | by Saul Dobilas | Towards Data Science
Most of you may already be familiar with clustering algorithms such as K-Means, HAC, or DBSCAN. However, clustering is not the only unsupervised way to find similarities between data points. You can also use association rule learning techniques to determine if certain data points (actions) are more likely to occur toge...
[ { "code": null, "e": 498, "s": 172, "text": "Most of you may already be familiar with clustering algorithms such as K-Means, HAC, or DBSCAN. However, clustering is not the only unsupervised way to find similarities between data points. You can also use association rule learning techniques to determi...
How to add a navigation menu on an image with CSS?
Following is the code to add a navigation menu on an image using CSS − Live Demo <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Document</title> <style> body{ margin:0px; margin-top:10px; padding: 0px; } nav{ widt...
[ { "code": null, "e": 1133, "s": 1062, "text": "Following is the code to add a navigation menu on an image using CSS −" }, { "code": null, "e": 1144, "s": 1133, "text": " Live Demo" }, { "code": null, "e": 2242, "s": 1144, "text": "<!DOCTYPE html>\n<html lang=\...
Create MySQL column with Key=MUL?
You need to use ADD KEY to make a column with Key=MUL. The syntax is as follows − ALTER TABLE yourTableName MODIFY COLUMN yourColumnName data type, ADD KEY(yourColumnName); To understand the above syntax, let us create a table. The query to create a table is as follows − mysql> create table Instructor -> ( -> Ins...
[ { "code": null, "e": 1144, "s": 1062, "text": "You need to use ADD KEY to make a column with Key=MUL. The syntax is as follows −" }, { "code": null, "e": 1235, "s": 1144, "text": "ALTER TABLE yourTableName MODIFY COLUMN yourColumnName data type,\nADD KEY(yourColumnName);" }, ...
Byte compare() method in Java with examples - GeeksforGeeks
05 Dec, 2018 The compare() method of Byte class is a built in method in Java which is used to compare two byte values. Syntax Byte.compare(byte a, byte b) Parameters: It takes two byte value ‘a’ and ‘b’ as input in the parameters which are to be compared. Return Value: It returns an int value. It returns: 0 if ‘a is eq...
[ { "code": null, "e": 24740, "s": 24712, "text": "\n05 Dec, 2018" }, { "code": null, "e": 24846, "s": 24740, "text": "The compare() method of Byte class is a built in method in Java which is used to compare two byte values." }, { "code": null, "e": 24853, "s": 2484...
JavaFX | Ellipse with examples - GeeksforGeeks
31 Oct, 2019 Ellipse class is a part of the JavaFX library. The ellipse class creates an ellipse on providing the center and X and Y radius. Ellipse class extends Shape class. Constructors of the class are: Ellipse(): creates an empty instance of ellipseEllipse(double X, double Y): creates a ellipse with the given x an...
[ { "code": null, "e": 23557, "s": 23529, "text": "\n31 Oct, 2019" }, { "code": null, "e": 23720, "s": 23557, "text": "Ellipse class is a part of the JavaFX library. The ellipse class creates an ellipse on providing the center and X and Y radius. Ellipse class extends Shape class."...
How to place two divs next to each other in HTML?
With CSS properties, you can easily put two <div> next to each other in HTML. Use the CSS property float to achieve this. With that, add height:100px and set margin. You can try to run the following code to place two <div> side by side − Live Demo <!DOCTYPE html> <html> <head> <title>HTML div</title> </head> <body> <di...
[ { "code": null, "e": 1184, "s": 1062, "text": "With CSS properties, you can easily put two <div> next to each other in HTML. Use the CSS property float to achieve this." }, { "code": null, "e": 1228, "s": 1184, "text": "With that, add height:100px and set margin." }, { "c...
Java static block
static keyword can be used to create a block to be used to initialize static variables. This static block executes when classloader loads the class. A static block is invoked before main() method. You can verify the same using. Live Demo public class Tester { static { System.out.println("In static block"); ...
[ { "code": null, "e": 1150, "s": 1062, "text": "static keyword can be used to create a block to be used to initialize static variables." }, { "code": null, "e": 1291, "s": 1150, "text": " This static block executes when classloader loads the class. A static block is invoked before...
CSS - Swing Effect
It provides move or cause to move back and forth or from side to side while suspended or on an axis to an element. @keyframes swing { 20% { transform: rotate(15deg); } 40% { transform: rotate(-10deg); } 60% { transform: rotate(5deg); } 80% { transform: rotate(-5deg); } 100% { transform: rotate(0deg)...
[ { "code": null, "e": 2741, "s": 2626, "text": "It provides move or cause to move back and forth or from side to side while suspended or on an axis to an element." }, { "code": null, "e": 2954, "s": 2741, "text": "@keyframes swing { \n 20% { transform: rotate(15deg); } \n 40% ...
Sort rows or columns in Pandas Dataframe based on values - GeeksforGeeks
02 Jul, 2020 In this article, Let’s discuss how to Sort rows or columns in Pandas Dataframe based on values. Pandas sort_values() method sorts a data frame in Ascending or Descending order of passed Column. It’s different than the sorted Python function since it cannot sort a data frame and particular column cannot be ...
[ { "code": null, "e": 24653, "s": 24625, "text": "\n02 Jul, 2020" }, { "code": null, "e": 24970, "s": 24653, "text": "In this article, Let’s discuss how to Sort rows or columns in Pandas Dataframe based on values. Pandas sort_values() method sorts a data frame in Ascending or Desc...
How to uninstall software using WMI in PowerShell?
There are mainly 3 methods by which you can uninstall software using PowerShell. WMI Method. WMI Method. Using Package provider Using Package provider Uninstallation String. Uninstallation String. We will discuss here the WMI method to uninstall software. With WMI class Win32_Product you can retrieve the list of softwa...
[ { "code": null, "e": 1143, "s": 1062, "text": "There are mainly 3 methods by which you can uninstall software using PowerShell." }, { "code": null, "e": 1155, "s": 1143, "text": "WMI Method." }, { "code": null, "e": 1167, "s": 1155, "text": "WMI Method." }, ...
How to Fix “Failed to install the following Android SDK packages as some licenses have not been accepted” Error in Android Studio? - GeeksforGeeks
31 Mar, 2021 When you download the latest Android SDK tools version using the command line to install SDKs and you just try to build gradle then this error shows up: Failed to install the following Android SDK packages as some licenses have not been accepted. platforms;android-27 Android SDK Platform 27 build-tools;27...
[ { "code": null, "e": 24926, "s": 24895, "text": " \n31 Mar, 2021\n" }, { "code": null, "e": 25079, "s": 24926, "text": "When you download the latest Android SDK tools version using the command line to install SDKs and you just try to build gradle then this error shows up:" }, ...
Major Activities of an Operating System with Regard to Secondary Storage Management
Secondary storage devices are non-volatile devices where the data is stored for long-term storage. Disks are the mainly used secondary storage devices. They provide the bulk of secondary storage in operating systems today. The main activity that is performed in secondary storage management is disk scheduling. There are...
[ { "code": null, "e": 1285, "s": 1062, "text": "Secondary storage devices are non-volatile devices where the data is stored for long-term storage. Disks are the mainly used secondary storage devices. They provide the bulk of secondary storage in operating systems today." }, { "code": null, ...
How to add a TextView to a LinearLayout dynamically in Android using Kotlin?
This example demonstrates how to add a TextView to a LinearLayout dynamically 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" enc...
[ { "code": null, "e": 1165, "s": 1062, "text": "This example demonstrates how to add a TextView to a LinearLayout dynamically in Android using Kotlin." }, { "code": null, "e": 1294, "s": 1165, "text": "Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and f...
VBScript - Dialog Boxes
VBScript allows the developers to interact with the user effectively. It can be a message box to display a message to a user or an input box with which user can enter the values. The MsgBox function displays a message box and waits for the user to click a button and then an action is performed based on the button click...
[ { "code": null, "e": 2259, "s": 2080, "text": "VBScript allows the developers to interact with the user effectively. It can be a message box to display a message to a user or an input box with which user can enter the values." }, { "code": null, "e": 2416, "s": 2259, "text": "The...
HTML5 Canvas - Pattern and Shadow
There is following method required to create a pattern on the canvas − createPattern(image, repetition) This method will use image to create the pattern. The second argument could be a string with one of the following values: repeat, repeat-x, repeaty, andno-repeat. If the empty string or null is specified, repeat will...
[ { "code": null, "e": 2679, "s": 2608, "text": "There is following method required to create a pattern on the canvas −" }, { "code": null, "e": 2712, "s": 2679, "text": "createPattern(image, repetition)" }, { "code": null, "e": 2941, "s": 2712, "text": "This me...
How to convert Varchar to Double in SQL?
You can convert varchar to double using CAST() function. The syntax is as follows: SELECT yourColumnName1,yourColumnName2,......N, CAST(yourColumnName AS DECIMAL(TotalDigit,DigitAfterDecimalPoint)) anyVariableName FROM yourtableName ORDER BY anyVariableName DESC; To understand the above syntax, let us create a table. T...
[ { "code": null, "e": 1145, "s": 1062, "text": "You can convert varchar to double using CAST() function. The syntax is as follows:" }, { "code": null, "e": 1326, "s": 1145, "text": "SELECT yourColumnName1,yourColumnName2,......N, CAST(yourColumnName AS DECIMAL(TotalDigit,DigitAfte...
LocalDate format() method in Java - GeeksforGeeks
28 Nov, 2018 The format() method of LocalDate class in Java method formats this date using the specified formatter. Syntax: public String format(DateTimeFormatter formatter) Parameter: This method accepts a parameter obj which specifies the formatter to be used and it is not null. Exceptions: The function throws only ...
[ { "code": null, "e": 23791, "s": 23763, "text": "\n28 Nov, 2018" }, { "code": null, "e": 23894, "s": 23791, "text": "The format() method of LocalDate class in Java method formats this date using the specified formatter." }, { "code": null, "e": 23902, "s": 23894, ...
Draw an Olympic Symbol in Python using Turtle - GeeksforGeeks
04 Apr, 2022 Prerequisites: Turtle Programming in Python The Olympic rings are five interlaced rings, colored blue, yellow, black, green, and red on a white field. As shown in the below image. import Turtle module set the thickness for each ring draw each circle with specific coordinates Below is the implementation. Py...
[ { "code": null, "e": 24219, "s": 24191, "text": "\n04 Apr, 2022" }, { "code": null, "e": 24263, "s": 24219, "text": "Prerequisites: Turtle Programming in Python" }, { "code": null, "e": 24399, "s": 24263, "text": "The Olympic rings are five interlaced rings, c...
How to get value of data attribute and use it in jQuery?
To get value of data attribute, use − $(“yourSelector”).data() The following is our input type with data attribute − <input type="text" id="txtValue" src="" data-value="90"> Following is the code − Live Demo <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=devic...
[ { "code": null, "e": 1100, "s": 1062, "text": "To get value of data attribute, use −" }, { "code": null, "e": 1125, "s": 1100, "text": "$(“yourSelector”).data()" }, { "code": null, "e": 1179, "s": 1125, "text": "The following is our input type with data attrib...
HTML <object> data Attribute
Tha data attribute of the <object> element sets the URL of the resource, which can be audio, video, pdf, flash, etc. used by the object. Following is the syntax: <object data="url"> The url is the URL of the resource used by the object. Let us now see an example to implement the data attribute of the <object> element: ...
[ { "code": null, "e": 1199, "s": 1062, "text": "Tha data attribute of the <object> element sets the URL of the resource, which can be audio, video, pdf, flash, etc. used by the object." }, { "code": null, "e": 1224, "s": 1199, "text": "Following is the syntax:" }, { "code"...
LESS - Import Options Reference Keyword
The @import (reference) is used to import external files but it will not add imported styles to compiled CSS file. This was released in version 1.5.0. The following example demonstrates the use of reference keyword in the LESS file − <html> <head> <link rel = "stylesheet" href = "style.css" type = "text/css" />...
[ { "code": null, "e": 2701, "s": 2550, "text": "The @import (reference) is used to import external files but it will not add imported styles to compiled CSS file. This was released in version 1.5.0." }, { "code": null, "e": 2784, "s": 2701, "text": "The following example demonstra...
How to convert pixels to DP’s in Android app?
This example demonstrates about How do I convert Pixels to DP’s 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"?> <RelativeLa...
[ { "code": null, "e": 1138, "s": 1062, "text": "This example demonstrates about How do I convert Pixels to DP’s in Android." }, { "code": null, "e": 1267, "s": 1138, "text": "Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required details to...
Cypress - Reports
Cypress is bundled with Mocha. So, any reports that can be generated for Mocha, can also be utilised with Cypress. In addition to that Cypress has other third party reporters like JUnit and teamcity. The Mochawesome report is one of the most important reports in Cypress. To install mochawesome, run the command given he...
[ { "code": null, "e": 2697, "s": 2497, "text": "Cypress is bundled with Mocha. So, any reports that can be generated for Mocha, can also be utilised with Cypress. In addition to that Cypress has other third party reporters like JUnit and teamcity." }, { "code": null, "e": 2769, "s": 2...
Understanding ELECTRA and Training an ELECTRA Language Model | by Thilina Rajapakse | Towards Data Science
Introduction What Is Pre-Training? Masked Language Modelling (MLM) ELECTRA Pre-Training Approach Efficiency Gains of the ELECTRA Approach Training Your Own ELECTRA Model Installation Data preparation Language Modeling Model Training the model Throwing out the generator and getting the discriminator Fine-tuning the pre-...
[ { "code": null, "e": 185, "s": 172, "text": "Introduction" }, { "code": null, "e": 207, "s": 185, "text": "What Is Pre-Training?" }, { "code": null, "e": 239, "s": 207, "text": "Masked Language Modelling (MLM)" }, { "code": null, "e": 269, "s":...
Overview of Data Binding in Android Architecture Components - GeeksforGeeks
09 May, 2021 This article describes the idea behind the Data Binding and MVVM design pattern and its components. If you would like to experiment with it hands-on, open an old project with spaghetti code. If you don’t have one, you’ll get one from GitHub. Then, attempt to use the MVVM components introduced during this a...
[ { "code": null, "e": 24522, "s": 24494, "text": "\n09 May, 2021" }, { "code": null, "e": 24837, "s": 24522, "text": "This article describes the idea behind the Data Binding and MVVM design pattern and its components. If you would like to experiment with it hands-on, open an old p...
Date format validation using C# Regex
Use the DateTime.TryParseExact method in C# for Date Format validation. They method converts the specified string representation of a date and time to its DateTime equivalent. It checks whether the entered date format is correct or not. Live Demo using System; using System.Globalization; namespace Demo { class Pro...
[ { "code": null, "e": 1134, "s": 1062, "text": "Use the DateTime.TryParseExact method in C# for Date Format validation." }, { "code": null, "e": 1299, "s": 1134, "text": "They method converts the specified string representation of a date and time to its DateTime equivalent. It che...
Difference between == and is operator in python.
is and equals(==) operators are mostly same but they are not same. is operator defines if both the variables point to the same object whereas the == sign checks if the values for the two variables are the same. # Python program to # illustrate the # difference between # == and is operator # [] is an empty list l...
[ { "code": null, "e": 1273, "s": 1062, "text": "is and equals(==) operators are mostly same but they are not same. is operator defines if both the variables point to the same object whereas the == sign checks if the values for the two variables are the same." }, { "code": null, "e": 1628,...
What is Type casting in C#?
Type casting is converting one type of data to another type. The two forms are − Implicit type conversion − These conversions are performed by C# in a type-safe manner. For example, are conversions from smaller to larger integral types and conversions from derived classes to base classes. Explicit type conversion− Thes...
[ { "code": null, "e": 1143, "s": 1062, "text": "Type casting is converting one type of data to another type. The two forms are −" }, { "code": null, "e": 1352, "s": 1143, "text": "Implicit type conversion − These conversions are performed by C# in a type-safe manner. For example, ...
How to count values from a PHP array and show value only once in a foreach loop?
Let’s say the following is our PHP array $listOfNames = array('John','David','Mike','David','Mike','David'); We want the output to display the count of values in the above array like this − Array ( [John] => 1 [David] => 3 [Mike] => 2 ) To get the count, use inbuilt function array_count_values(). The PHP code is as fo...
[ { "code": null, "e": 1104, "s": 1062, "text": "Let’s say the following is our PHP array " }, { "code": null, "e": 1172, "s": 1104, "text": "$listOfNames = array('John','David','Mike','David','Mike','David');" }, { "code": null, "e": 1253, "s": 1172, "text": "W...
VBScript Exit Do statement
An Exit Do Statement is used when we want to Exit the Do Loops based on certain criteria. It can be used within both Do..While and Do..Until Loops. When Exit Do is executed, the control jumps to next statement immediately after the Do Loop. The syntax for Exit Do Statement in VBScript is − Exit Do The below example u...
[ { "code": null, "e": 2228, "s": 2080, "text": "An Exit Do Statement is used when we want to Exit the Do Loops based on certain criteria. It can be used within both Do..While and Do..Until Loops." }, { "code": null, "e": 2321, "s": 2228, "text": "When Exit Do is executed, the cont...
Get the storage size of a database in MongoDB?
To get the storage size of a database in MongoDB, use the stats() method. At first, check the current database with the help of the following query − > db; The following is the output − test Here is the query to get the storage size of the database in MongoDB − > db.stats() The following is the output displaying the st...
[ { "code": null, "e": 1136, "s": 1062, "text": "To get the storage size of a database in MongoDB, use the stats() method." }, { "code": null, "e": 1212, "s": 1136, "text": "At first, check the current database with the help of the following query −" }, { "code": null, ...
Java Arrays
Arrays are used to store multiple values in a single variable, instead of declaring separate variables for each value. To declare an array, define the variable type with square brackets: String[] cars; We have now declared a variable that holds an array of strings. To insert values to it, we can use an array literal...
[ { "code": null, "e": 120, "s": 0, "text": "Arrays are used to store multiple values in a single variable, instead of declaring separate variables for each \nvalue." }, { "code": null, "e": 188, "s": 120, "text": "To declare an array, define the variable type with square brackets:...
Minimum length of jumps to avoid given array of obstacles - GeeksforGeeks
27 May, 2021 We are given coordinates of obstacles on a straight line. We start jumping from point 0, we need to reach the end, avoiding all obstacles. The length of every jump has to be the same (For example, if we jump from 0 to 4, then we must make the next jump from 4 to 8). We need to find the minimum length of th...
[ { "code": null, "e": 24429, "s": 24401, "text": "\n27 May, 2021" }, { "code": null, "e": 24800, "s": 24429, "text": "We are given coordinates of obstacles on a straight line. We start jumping from point 0, we need to reach the end, avoiding all obstacles. The length of every jump...
CSS text-rendering - GeeksforGeeks
27 Nov, 2020 Text-rendering is a property that allows you to choose what to optimize when rendering text. It sends the information to the rendering engine about what to optimize for while rendering text. It’s actually not a CSS property and is not defined in any CSS standard. It’s an SVG property but Gecko and Webkit ...
[ { "code": null, "e": 24985, "s": 24957, "text": "\n27 Nov, 2020" }, { "code": null, "e": 25177, "s": 24985, "text": "Text-rendering is a property that allows you to choose what to optimize when rendering text. It sends the information to the rendering engine about what to optimiz...
How to Fix ValueError: The truth value of a Series is ambiguous in Pandas | Towards Data Science
One of the most commonly reported error in pandas is ValueError: The truth value of a Series is ambiguous. Use a.empty, a.bool(), a.item(), a.any() or a.all() and it may sometimes be quite tricky to deal with, especially if you are new to pandas library (or even Python). In today’s article, we are going to understand w...
[ { "code": null, "e": 225, "s": 172, "text": "One of the most commonly reported error in pandas is" }, { "code": null, "e": 331, "s": 225, "text": "ValueError: The truth value of a Series is ambiguous. Use a.empty, a.bool(), a.item(), a.any() or a.all()" }, { "code": null,...
Deploying Streamlit apps using Streamlit sharing | by Tyler Richards | Towards Data Science
Over the past couple of weeks, I’ve been playing around with a new Streamlit feature called Streamlit sharing, which makes it super easy to deploy your custom apps. I’m going to go through a bit of background first, so if you want to see the docs for Streamlit sharing to get started you can find them here. For a bit of...
[ { "code": null, "e": 480, "s": 172, "text": "Over the past couple of weeks, I’ve been playing around with a new Streamlit feature called Streamlit sharing, which makes it super easy to deploy your custom apps. I’m going to go through a bit of background first, so if you want to see the docs for Stre...
Optimization with SciPy and application ideas to machine learning | by Tirthajyoti Sarkar | Towards Data Science
You may remember a simple calculus problem from the high school days — finding the minimum amount of material needed to build a box given a restriction on its volume. Simple enough? It is useful to ponder a bit on this problem and to recognize that the same principle applied here, finds widespread use in complex, large...
[ { "code": null, "e": 338, "s": 171, "text": "You may remember a simple calculus problem from the high school days — finding the minimum amount of material needed to build a box given a restriction on its volume." }, { "code": null, "e": 353, "s": 338, "text": "Simple enough?" }...
SUMIF in 5 languages (VBA/SQL/PYTHON/M query/DAX powerBI) | by Aymen | Towards Data Science
Excel is a powerful spreadsheet used by most people working in data analysis. The increase of volume of data and development user-friendly tools is an opportunity of improvement of Excel reports by mixing them with another tool or language. As working for a financial reporting department I faced the need to boost our r...
[ { "code": null, "e": 413, "s": 172, "text": "Excel is a powerful spreadsheet used by most people working in data analysis. The increase of volume of data and development user-friendly tools is an opportunity of improvement of Excel reports by mixing them with another tool or language." }, { ...
PyQt - QTab Widget
If a form has too many fields to be displayed simultaneously, they can be arranged in different pages placed under each tab of a Tabbed Widget. The QTabWidget provides a tab bar and a page area. The page under the first tab is displayed and others are hidden. The user can view any page by clicking on the desired tab. F...
[ { "code": null, "e": 2245, "s": 1926, "text": "If a form has too many fields to be displayed simultaneously, they can be arranged in different pages placed under each tab of a Tabbed Widget. The QTabWidget provides a tab bar and a page area. The page under the first tab is displayed and others are h...
Inorder Traversal of a Threaded Binary Tree in C++
Here we will see the threaded binary tree data structure. We know that the binary tree nodes may have at most two children. But if they have only one children, or no children, the link part in the linked list representation remains null. Using threaded binary tree representation, we can reuse that empty links by making...
[ { "code": null, "e": 1397, "s": 1062, "text": "Here we will see the threaded binary tree data structure. We know that the binary tree nodes may have at most two children. But if they have only one children, or no children, the link part in the linked list representation remains null. Using threaded ...
Geek and Contest || | Practice | GeeksforGeeks
Geek hosted a contest and N students participated in it. The score of each student is given by an integer array arr[]. The task is to print the number of each student (indexes) in the order they appear on the scoreboard. A student with a maximum score appears first. If two people have the same score then a higher index...
[ { "code": null, "e": 584, "s": 226, "text": "Geek hosted a contest and N students participated in it. The score of each student is given by an integer array arr[]. The task is to print the number of each student (indexes) in the order they appear on the scoreboard.\nA student with a maximum score ap...
Program for decimal to hexadecimal conversion - GeeksforGeeks
06 Apr, 2022 Given a decimal number as input, we need to write a program to convert the given decimal number into equivalent hexadecimal number. i.e convert the number with base value 10 to base value 16. Hexadecimal numbers uses 16 values to represent a number. Numbers from 0-9 are expressed by digits 0-9 and 10-15 ar...
[ { "code": null, "e": 26017, "s": 25989, "text": "\n06 Apr, 2022" }, { "code": null, "e": 26209, "s": 26017, "text": "Given a decimal number as input, we need to write a program to convert the given decimal number into equivalent hexadecimal number. i.e convert the number with bas...
How to handle python exception inside if statement?
The code can be written as follows to catch the exception a, b=5, 0 try: if b != 0: print a/b else: a/b raise ZeroDivisionError except Exception as e: print e We get the following output C:/Users/TutorialsPoint1/~.py integer division or modulo by zero
[ { "code": null, "e": 1120, "s": 1062, "text": "The code can be written as follows to catch the exception" }, { "code": null, "e": 1255, "s": 1120, "text": "a, b=5, 0\ntry:\n if b != 0:\n print a/b\n else:\n a/b\n raise ZeroDivisionError\nexcept Exception as ...
Snake and Ladder Problem | Practice | GeeksforGeeks
Given a 5x6 snakes and ladders board, find the minimum number of dice throws required to reach the destination or last cell (30th cell) from the source (1st cell). You are given an integer N denoting the total number of snakes and ladders and an array arr[] of 2*N size where 2*i and (2*i + 1)th values denote the start...
[ { "code": null, "e": 403, "s": 238, "text": "Given a 5x6 snakes and ladders board, find the minimum number of dice throws required to reach the destination or last cell (30th cell) from the source (1st cell). " }, { "code": null, "e": 652, "s": 403, "text": "You are given an inte...
Number of digits in 2 raised to power n - GeeksforGeeks
06 Apr, 2021 Let n be any power raised to base 2 i.e 2n. We are given the number n and our task is to find out the number of digits contained in the number 2n.Examples: Input : n = 5 Output : 2 Explanation : 2n = 32, which has only 2 digits. Input : n = 10 Output : 4 Explanation : 2n = 1024, which has only 4 digits. ...
[ { "code": null, "e": 26073, "s": 26045, "text": "\n06 Apr, 2021" }, { "code": null, "e": 26230, "s": 26073, "text": "Let n be any power raised to base 2 i.e 2n. We are given the number n and our task is to find out the number of digits contained in the number 2n.Examples: " }, ...
Statistical plotting with relplot() | Towards Data Science
The goal of this article is that you come away with a strong knowledge of any type of statistical plotting of quantitative variables using Seaborn’s relplot() function. When I started learning Data Visualization, I was first introduced to Matplotlib. It is a library that is so vast and deep, you can visualize almost an...
[ { "code": null, "e": 341, "s": 172, "text": "The goal of this article is that you come away with a strong knowledge of any type of statistical plotting of quantitative variables using Seaborn’s relplot() function." }, { "code": null, "e": 591, "s": 341, "text": "When I started le...
Prettify JSON data in textarea input in JavaScript?
For this, use JSON.parse() along with JSON.stringify(). Live Demo <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initialscale=1.0"> <title>Document</title> <link rel="stylesheet" href="//code.jquery.com/ui/1.12.1/themes/base/jquery-ui.css"> <script src...
[ { "code": null, "e": 1118, "s": 1062, "text": "For this, use JSON.parse() along with JSON.stringify()." }, { "code": null, "e": 1129, "s": 1118, "text": " Live Demo" }, { "code": null, "e": 2145, "s": 1129, "text": "<!DOCTYPE html>\n<html lang=\"en\">\n<head>\...
Annotated Heatmaps of a Correlation Matrix in 5 Simple Steps | by Julia Kho | Towards Data Science
A heatmap is a graphical representation of data in which data values are represented as colors. That is, it uses color in order to communicate a value to the reader. This is a great tool to assist the audience towards the areas that matter the most when you have a large volume of data. In this article, I will guide you...
[ { "code": null, "e": 459, "s": 172, "text": "A heatmap is a graphical representation of data in which data values are represented as colors. That is, it uses color in order to communicate a value to the reader. This is a great tool to assist the audience towards the areas that matter the most when y...
Flow control in try catch finally in Java - GeeksforGeeks
25 Jun, 2021 In this article, we’ll explore all the possible combinations of try-catch-finally which may happen whenever an exception is raised and how the control flow occurs in each of the given cases. Control flow in try-catch clause OR try-catch-finally clause Case 1: Exception occurs in try block and handled in c...
[ { "code": null, "e": 28870, "s": 28842, "text": "\n25 Jun, 2021" }, { "code": null, "e": 29062, "s": 28870, "text": "In this article, we’ll explore all the possible combinations of try-catch-finally which may happen whenever an exception is raised and how the control flow occurs ...
Java Examples - Parent Directory
How to get the parent directory of a file ? Following example shows how to get the parent directory of a file by the use of file.getParent() method of File class. import java.io.File; public class Main { public static void main(String[] args) { File file = new File("C:/File/demo.txt"); String strParent...
[ { "code": null, "e": 2112, "s": 2068, "text": "How to get the parent directory of a file ?" }, { "code": null, "e": 2231, "s": 2112, "text": "Following example shows how to get the parent directory of a file by the use of file.getParent() method of File class." }, { "code...
How to generate synthetic tabular data? | by Fabiana Clemente | Towards Data Science
I’ve covered in the past what are Generative Adversarial Networks, and how we can use them to generate data that is private by design, in a blog post where I cover both the Vanilla GAN and Conditional GAN. But, although pretty promising, these Generative Adversarial Networks are very challenging to train, and the data ...
[ { "code": null, "e": 794, "s": 172, "text": "I’ve covered in the past what are Generative Adversarial Networks, and how we can use them to generate data that is private by design, in a blog post where I cover both the Vanilla GAN and Conditional GAN. But, although pretty promising, these Generative ...
Counts paths from a point to reach Origin
02 Feb, 2022 You are standing on a point (n, m) and you want to go to origin (0, 0) by taking steps either left or down i.e. from each point you are allowed to move either in (n-1, m) or (n, m-1). Find the number of paths from point to origin. Examples: Input : 3 6 Output : Number of Paths 84 Input : 3 0 Output : Num...
[ { "code": null, "e": 52, "s": 24, "text": "\n02 Feb, 2022" }, { "code": null, "e": 283, "s": 52, "text": "You are standing on a point (n, m) and you want to go to origin (0, 0) by taking steps either left or down i.e. from each point you are allowed to move either in (n-1, m) or ...
Structured Analysis
Analysts use various tools to understand and describe the information system. One of the ways is using structured analysis. Structured Analysis is a development method that allows the analyst to understand the system and its activities in a logical way. It is a systematic approach, which uses graphical tools that analy...
[ { "code": null, "e": 2131, "s": 2007, "text": "Analysts use various tools to understand and describe the information system. One of the ways is using structured analysis." }, { "code": null, "e": 2261, "s": 2131, "text": "Structured Analysis is a development method that allows th...
std::bit_xor in C++ with Examples
01 May, 2020 The bit_xor is an inbuilt function in C++ which is used to perform bitwise_xor and return the result after applying the bitwise_xor operation on it’s arguments. Header File: #include <functional.h> Template Class: template <class T> struct bit_xor; Parameters: It accepts a parameter T which is the type o...
[ { "code": null, "e": 54, "s": 26, "text": "\n01 May, 2020" }, { "code": null, "e": 215, "s": 54, "text": "The bit_xor is an inbuilt function in C++ which is used to perform bitwise_xor and return the result after applying the bitwise_xor operation on it’s arguments." }, { ...
What is Open API in UNIX?
04 Dec, 2020 There is a set of generic APIs in UNIX which is used to manipulate files. One of these APIs is the open API. The open API is used to create new files and also to establish a connection between a process and a file. After a file is created, any process can call the open function and it gets a file descripto...
[ { "code": null, "e": 53, "s": 25, "text": "\n04 Dec, 2020" }, { "code": null, "e": 473, "s": 53, "text": "There is a set of generic APIs in UNIX which is used to manipulate files. One of these APIs is the open API. The open API is used to create new files and also to establish a ...
Python - Email Messages
Email is a service which allows us to send the message in electronic mode over the internet. It offers an efficient, inexpensive and real time mean of distributing information among people. Each user of email is assigned a unique name for his email account. This name is known as E-mail address. Different users can send...
[ { "code": null, "e": 2650, "s": 2460, "text": "Email is a service which allows us to send the message in electronic mode over the internet. It offers an efficient, inexpensive and real time mean of distributing information among people." }, { "code": null, "e": 2835, "s": 2650, "...
GATE | GATE CS 2018 | Question 61
22 Nov, 2021 The instruction pipeline of a RISC processor has the following stages: Instruction Fetch (IF), Instruction Decode (ID), Operand Fetch (OF), Perform Operation (PO) and Writeback (WB), The IF, ID, OF and WB stages take 1 clock cycle each for every instruction. Consider a sequence of 100 instructions. In the ...
[ { "code": null, "e": 28, "s": 0, "text": "\n22 Nov, 2021" }, { "code": null, "e": 550, "s": 28, "text": "The instruction pipeline of a RISC processor has the following stages: Instruction Fetch (IF), Instruction Decode (ID), Operand Fetch (OF), Perform Operation (PO) and Writebac...
C++ Program For Removing Duplicates From An Unsorted Linked List
14 Dec, 2021 Write a removeDuplicates() function that takes a list and deletes any duplicate nodes from the list. The list is not sorted. For example if the linked list is 12->11->12->21->41->43->21 then removeDuplicates() should convert the list to 12->11->21->41->43. METHOD 1 (Using two loops): This is the simple way...
[ { "code": null, "e": 28, "s": 0, "text": "\n14 Dec, 2021" }, { "code": null, "e": 285, "s": 28, "text": "Write a removeDuplicates() function that takes a list and deletes any duplicate nodes from the list. The list is not sorted. For example if the linked list is 12->11->12->21->...
Program to Convert Radian to Degree
23 Jun, 2022 Before moving to the actual solution, let’s try to find out what is a degree, a radian, and their relations. Radian : The radian is the standard unit of angular measure, used in many areas of mathematics. The length of an arc of a unit circle is numerically equal to the measurement in radians of the angle ...
[ { "code": null, "e": 28, "s": 0, "text": "\n23 Jun, 2022" }, { "code": null, "e": 137, "s": 28, "text": "Before moving to the actual solution, let’s try to find out what is a degree, a radian, and their relations." }, { "code": null, "e": 392, "s": 137, "text"...
SQL Query to Display Last 5 Records from Employee Table
06 Aug, 2021 Summary : Here we will be learning how to retrieve last 5 rows from a database table with the help of SQL queries. The Different Approaches we are going to explore are : With the help of LIMIT clause in descending order. With the help of Relational operator and COUNT function. With the help of Prepared Sta...
[ { "code": null, "e": 28, "s": 0, "text": "\n06 Aug, 2021" }, { "code": null, "e": 38, "s": 28, "text": "Summary :" }, { "code": null, "e": 143, "s": 38, "text": "Here we will be learning how to retrieve last 5 rows from a database table with the help of SQL qu...
DateTime.ToLocalTime() Method in C#
11 Feb, 2019 This method is used to convert the value of the current DateTime object to local time. Syntax: public DateTime ToLocalTime (); Return Value: This method returns an object whose Kind property is Local, and whose value is the local time equivalent to the value of the current DateTime object, or MaxValue if t...
[ { "code": null, "e": 28, "s": 0, "text": "\n11 Feb, 2019" }, { "code": null, "e": 115, "s": 28, "text": "This method is used to convert the value of the current DateTime object to local time." }, { "code": null, "e": 155, "s": 115, "text": "Syntax: public Date...
Tourism Management System in C/C++
22 Sep, 2021 The Tourism Management System is implemented by C programming. It is as same as one can see while going for online booking. Here, the underlying idea is to present users with two choices International or India Tour packages. Then according to the choice, the available packages will be displayed. The next ...
[ { "code": null, "e": 28, "s": 0, "text": "\n22 Sep, 2021" }, { "code": null, "e": 516, "s": 28, "text": "The Tourism Management System is implemented by C programming. It is as same as one can see while going for online booking. Here, the underlying idea is to present users with ...
Make alphabets using the elements of an array - GeeksforGeeks
21 May, 2021 Given an array of positive integers, find all the alphabets that we can make using elements of the array. Examples : Input : arr[] = {6, 5} Output : A In this example, we can take 6 and 5 as 65 that gives us A. Input : arr[] = {5, 6, 6} Output : A B Here we can take 6 and 5 as 65 to make A. And 6 and 6...
[ { "code": null, "e": 26067, "s": 26039, "text": "\n21 May, 2021" }, { "code": null, "e": 26186, "s": 26067, "text": "Given an array of positive integers, find all the alphabets that we can make using elements of the array. Examples : " }, { "code": null, "e": 26546, ...
Difference between break and continue in PHP - GeeksforGeeks
10 Apr, 2022 The break and continue both are used to skip the iteration of a loop. These keywords are helpful in controlling the flow of the program. Difference between break and continue: The break statement terminates the whole iteration of a loop whereas continue skips the current iteration.The break statement termi...
[ { "code": null, "e": 26313, "s": 26285, "text": "\n10 Apr, 2022" }, { "code": null, "e": 26489, "s": 26313, "text": "The break and continue both are used to skip the iteration of a loop. These keywords are helpful in controlling the flow of the program. Difference between break a...
State Design Pattern - GeeksforGeeks
01 Sep, 2021 State pattern is one of the behavioral design pattern. State design pattern is used when an Object changes its behavior based on its internal state. If we have to change behavior of an object based on its state, we can have a state variable in the Object and use if-else condition block to perform different...
[ { "code": null, "e": 25884, "s": 25856, "text": "\n01 Sep, 2021" }, { "code": null, "e": 26033, "s": 25884, "text": "State pattern is one of the behavioral design pattern. State design pattern is used when an Object changes its behavior based on its internal state." }, { ...
Explain the different types of Selectors in CSS - GeeksforGeeks
26 Sep, 2021 A CSS selector selects the HTML element(s) for styling purpose. CSS selectors select HTML elements according to its id, class, type, attribute etc. There are many basic different types of selectors. Element Selector Id Selector Class Selector Universal Selector Group Selector HTML code: Consider the sample...
[ { "code": null, "e": 26621, "s": 26593, "text": "\n26 Sep, 2021" }, { "code": null, "e": 26769, "s": 26621, "text": "A CSS selector selects the HTML element(s) for styling purpose. CSS selectors select HTML elements according to its id, class, type, attribute etc." }, { "...
C++ Floating Point Manipulation - GeeksforGeeks
10 Jan, 2022 Like integers, C++11 introduced some basic inbuilt functions for handling simple mathematical computations of floating-point numbers necessary for day-to-day programming as well as competitive programming. These functions belong to the <cmath> header file. This article discusses some of the functions intro...
[ { "code": null, "e": 25728, "s": 25700, "text": "\n10 Jan, 2022" }, { "code": null, "e": 26042, "s": 25728, "text": "Like integers, C++11 introduced some basic inbuilt functions for handling simple mathematical computations of floating-point numbers necessary for day-to-day progr...
How to Install BeautifulSoup in Python on MacOS? - GeeksforGeeks
14 Sep, 2021 In this article, we will learn how to install Beautiful Soup in Python on MacOS. Step 1: Install latest Python3 in MacOS Step 2: Check if pip3 and python3 are correctly installed. python3 --version pip3 --version Step 3: Upgrade your pip to avoid errors during installation. pip3 install --upgrade pip Step ...
[ { "code": null, "e": 26097, "s": 26069, "text": "\n14 Sep, 2021" }, { "code": null, "e": 26178, "s": 26097, "text": "In this article, we will learn how to install Beautiful Soup in Python on MacOS." }, { "code": null, "e": 26218, "s": 26178, "text": "Step 1: I...
Bash program to find A to the power B - GeeksforGeeks
02 Feb, 2018 Given two number A and B write a shell script to find the value of AB . Examples: Input : 2 4 Output : 2 to the power 4 is 16 Input : 1 0 Output : 1 to the power 0 is 1 A to the power B (AB) means multiplying A, B times. Using a naive approach to solve this problem.For Example:-A = 2 and B = 3A3 = 8 whi...
[ { "code": null, "e": 25677, "s": 25649, "text": "\n02 Feb, 2018" }, { "code": null, "e": 25749, "s": 25677, "text": "Given two number A and B write a shell script to find the value of AB ." }, { "code": null, "e": 25759, "s": 25749, "text": "Examples:" }, ...
Pushing changes to a Git Repository - GeeksforGeeks
08 Jan, 2020 Git allows performing various operations on the Repositories including the local repositories and remote repositories. The user when downloads a project to work upon, a local repository is created to store a copy of the original project. This local repository stores the changes that are being made by the u...
[ { "code": null, "e": 25521, "s": 25493, "text": "\n08 Jan, 2020" }, { "code": null, "e": 26719, "s": 25521, "text": "Git allows performing various operations on the Repositories including the local repositories and remote repositories. The user when downloads a project to work up...
Read/Write structure to a file in C - GeeksforGeeks
07 Oct, 2021 Prerequisite: Structure in CFor writing in file, it is easy to write string or int to file using fprintf and putc, but you might have faced difficulty when writing contents of struct. fwrite and fread make task easier when you want to write and read blocks of data. fwrite : Following is the declaration o...
[ { "code": null, "e": 25761, "s": 25733, "text": "\n07 Oct, 2021" }, { "code": null, "e": 26029, "s": 25761, "text": "Prerequisite: Structure in CFor writing in file, it is easy to write string or int to file using fprintf and putc, but you might have faced difficulty when writing...