A stadium was to be built in 1500 days. The contractor employed 200 men, 300 women and 750 robotic machines. After 600 days, 75% of… Read More

All Medium Articles

A person employed a group of 20 men for a construction job. These 20 men working 8 hours a day can complete the job in… Read More

Two friends A and B were employed to do a work. Initial deadline was fixed at 24 days. Both started working together but after 20… Read More

Given a graph and a source vertex in graph, find shortest paths from source to all vertices in the given graph. Input : Source =… Read More

Given a graph and a source vertex in graph, find shortest paths from source to all vertices in the given graph. Input : Source =… Read More

In C++ STL, there is priority_queue that can directly be used to implement Max Heap. In order to fully understand the code, make sure you… Read More

The HashSet class implements the Set interface, backed by a hash table which is actually a HashMap instance. No guarantee is made as to the… Read More

There is an array of ‘x’ and ‘o’. From each ‘x’ a signal originates which travels in both direction. It takes one unit of time… Read More

Two numbers are in the ratio of 5:7. If their LCM is 105, what is the difference between their squares ? (A) 216 (B) 210… Read More

Three friends started running together on a circular track at 8:00:00 am. Time taken by them to complete one round of the track is 15… Read More

Given a graph and a source vertex in graph, find shortest paths from source to all vertices in the given graph.We have discussed Dijkstra’s Shortest… Read More

This is one of the most used techniques in competitive programming. Let us first consider below simple question.What is the minimum time complexity to find… Read More

Suppose we want to create a class for Graph. The class stores adjacency matrix representation of the graph. Therefore, our class structure would be something… Read More

Which of the following DMA transfer modes and interrupt handling mechanisms will enable the highest I/O band-width? (A) Transparent DMA and Polling interrupts (B)… Read More

Given a boolean function f (x1, x2, …, xn), which of the following equations is NOT true (A) f (x1, x2, …, xn) =… Read More

Please see Set 1 for Execution, Stages and Performance (Throughput) and Set 3 for Types of Pipeline and Stalling. Dependencies in a pipelined processor… Read More

Background : In a flow network, an s-t cut is a cut that requires the source ‘s’ and the sink ‘t’ to be in different… Read More

Given a fraction, find a recurring sequence of digits if it exists, otherwise, print “No recurring sequence”. Examples: Input : Numerator = 8, Denominator =… Read More

Given N jobs where every job is represented by following three elements of it. Start Time Finish Time Profit or Value Associated Find the maximum… Read More