Article Categories
- All Categories
-
Data Structure
-
Networking
-
RDBMS
-
Operating System
-
Java
-
MS Excel
-
iOS
-
HTML
-
CSS
-
Android
-
Python
-
C Programming
-
C++
-
C#
-
MongoDB
-
MySQL
-
Javascript
-
PHP
-
Economics & Finance
Articles on Trending Technologies
Technical articles with clear explanations and examples
BlueStacks Alternatives
What is BlueStacks? BlueStacks is an app player which can be installed on Windows and Mac PC. The software enables you to play mobile games on PCs. BlueStacks app player has been developed for users who love to play games. They can enjoy their game through a mouse, keyboard, and gamepad. BlueStacks also provides customization options so that users can set up the game as per their comfort and preference. Cost of BlueStacks BlueStacks can be downloaded and used for free. It is compatible with almost all the apps available in the Google Play Store. Mostly Android users use the ...
Read MoreHow to update mouse location when scrolling with jQuery?
In jQuery, we can trigger the ‘mousemove’ event to detect the mouse pointer's location on the web page. Also, we can detect the scroll using the ‘scroll’ event and subtract that value from the y position to get the relative mouse location. Using the ‘overflow-y: scroll’ CSS property, we can make any div scrollable. Syntax Users can follow the syntax below to get the relative mouse position while scrolling on the div. $('#main').scroll(function (event) { if (finalScroll != $('#main').scrollTop()) { location_y -= finalScroll; finalScroll = ...
Read MoreHow to show/hide div element depending multiple values using Bootstrap and jQuery?
Sometimes, we may require to show and hide div based on the selected values. For example, you want to show the registration or login forms based on the radio button's selected value. Below, we will learn to show/hide the div elements based on the selected value using JQuery. Show/hide the div Element Depending on the Selected Value From the Select Menu In JQuery, we can get the selected option’s value from the ‘select’ menu. After that, we can access the div element according to the selected option value and show them. Syntax Users can follow the syntax below to show/div ...
Read MoreGolang program to implement dijikstra Algorithm to find shortest path between two nodes in a graph
In this Golang article, we will explore how to implement Dijkstra's Algorithm to find the shortest path between two nodes in a graph using an Adjacency Matrix as well as using an Adjacency List. Dijkstra's Algorithm is used to solve the single-source shortest path problem in a graph with non-negative edge weights. Algorithm Step 1 − First, we need to import the fmt and math packages. Then create a dist array of length n (the number of nodes in the graph) and initialize it with math.MaxInt32. This array will store the shortest distance from the starting node to every ...
Read MoreGolang program to implement merge sort
In this Golang article, we will learn how to implement Merge Sort in Golang using three different methods recursions, iteration and goroutines. Merge sort is one of the most efficient sorting Algorithms that uses the divide and conquer approach to sort a list of elements. Syntax func copy(dst, str[] type) int The copy function in go language is used to copy the values of one source array to the destination array and returns the number of elements copied as the result. It takes the two arrays as an argument. func len(v Type) int The len() function is used ...
Read MoreGolang program to find the minimum number of resources needed to complete all tasks simultaneously
In this Golang article, w will understand how to use interval scheduling Algorithm find the minimum number of resources needed to complete all the tasks simultaneously. Interval scheduling Algorithm is a type of Algorithm used to solve scheduling problems where a set of tasks with start and end times must be scheduled on a limited resource. Algorithm Step 1 − First, we need to import the fmt and Sort packages. Then initialize the required structs along with the functions. Step 2 − The task struct is used to track the start and end time of the task whereas ...
Read MoreGolang program to find the maximum number of classes that can be scheduled without conflicts
In this Golang article we are going to find the maximum number of classes that can be scheduled without conflicts, if there is a list of intervals representing classes. Here we are going to slice function to perform this task. Following Algorithm will help you understand the steps taken to creat the golang program. Algorithm Step 1 − First, we need to import the fmt and sort packages. Step 2 − Then, create a struct named interval and store in it the start and end variable. Step 3 − Now, start the main() function. Inside the main() Initialize the ...
Read MoreGolang program to find minimum spanning tree using dijkstra Algorithm
In this article we will write a go language program to find minimum spanning of tree. A minimum spanning tree (MST) is a tree that connects all the nodes in an undirected, weighted graph with the minimum possible edges. There are several Algorithms to find the minimum spanning tree of a graph like dijkastra Algorithm, prim's Algorithm and kruskal's Algorithm. What is Dijkistra Algorithm? Dijkstra's Algorithm is an Algorithm that finds the shortest path between a source vertex and all other vertices in a weighted graph with non-negative edge weights. It works by maintaining a set of visited vertices ...
Read MoreGolang program to find the last occurrence of a target element in a sorted slice
In this article, we will learn how to write a golang program to find the last occurrence of a target element in a sorted slice using linear and binary search approach. We will use two programs in this article. In the first program we will use the Linear search approach while in the second one we will use the binary search approach to implement the result. Using the Linear Search Approach The simplest method to find the last occurrence of a target element in a sorted slice is to perform a linear search. In this method, we iterate through the ...
Read MoreGo program to find the diameter of a graph using the Dijkstra Algorithm
In this article we will write a go language program to find the diameter of a graph. The diameter of a graph is the maximum distance between any two vertices in the graph. There are several Algorithms that can be used to find the diameter of a graph, including Dijkstra's Algorithm, Floyd-Warshall Algorithm, and Breadth-First Search Algorithm. Since, dijkastra Algorithm finds the shortest distance between source vertex and other vertices. We can also use it to find the largest distance by comparing the length of vertices recieved. Syntax func len(v Type) int The len() function is used to get ...
Read More