## Efficiently design Insert, Delete and Median queries on a set

Given an empty set initially and a number of queries on it, each possibly of the following types: Insert – Insert a new element ‘x’.… Read More »

## Directi Interview | Set 8 (Off-Campus)

I applied for Directi off-campus on its career website and I got a call. There were total 5 rounds. Online coding round: 1.5 hours There… Read More »

## Implementation of Tic-Tac-Toe game

Rules of the Game The game is to be played between two people (in this program between HUMAN and COMPUTER). One of the player chooses… Read More »

## Amazon Interview Experience | Set 264 (Experienced for SDE1)

I had around 1 year and 9 months of experience. And applied for SDE1 First Round (F2F): 1. What are data structures in which you… Read More »

## Queue Interface In Java

The Queue interface is available in java.util package and extends the Collection interface. The queue collection is used to hold the elements about to be… Read More »

## NaN in C++ – What is it and how to check for it?

What is NaN ? NaN, acronym for “Not a Number” is an exception which usually occurs in the cases when an expression results in a… Read More »

## Minimax Algorithm in Game Theory | Set 3 (Tic-Tac-Toe AI – Finding optimal move)

Prerequisites: Minimax Algorithm in Game Theory, Evaluation Function in Game Theory Let us combine what we have learnt so far about minimax and evaluation function… Read More »

## Sorting 2D Vector in C++ | Set 2 (In descending order by row and column)

We have discussed some of the cases of sorting 2D vector in below set 1. Sorting 2D Vector in C++ | Set 1 (By row… Read More »

## Python Program for BogoSort or Permutation Sort

BogoSort also known as permutation sort, stupid sort, slow sort, shotgun sort or monkey sort is a particularly ineffective algorithm based on generate and test… Read More »

## Java Program for BogoSort or Permutation Sort

BogoSort also known as permutation sort, stupid sort, slow sort, shotgun sort or monkey sort is a particularly ineffective algorithm based on generate and test… Read More »

## C++ Program for BogoSort or Permutation Sort

BogoSort also known as permutation sort, stupid sort, slow sort, shotgun sort or monkey sort is a particularly ineffective algorithm based on generate and test… Read More »

## BogoSort or Permutation Sort

BogoSort also known as permutation sort, stupid sort, slow sort, shotgun sort or monkey sort is a particularly ineffective algorithm based on generate and test… Read More »

## Find frequency of each element in a limited range array in less than O(n) time

Given an sorted array of positive integers, count number of occurrences for each element in the array. Assume all elements in the array are less… Read More »

## Print calendar for a given year in C++

Prerequisite : Find day of the week for given date Problem: To print the calendar of any given year. The program should be such that… Read More »

## Sorting 2D Vector in C++ | Set 1 (By row and column)

What is a 2D Vector? A 2D vector is vector of vectors. It is an matrix implemented with the help of vectors. filter_none edit close… Read More »