Service Lane

Cerinta completa A driver is driving on the freeway. The check engine light of his vehicle is on, and the driver wants to get service immediately. Luckily, a service lane runs parallel to the highway. It varies in width along

Substring Diff

Cerinta completa In this problem, we’ll use the term “longest common substring” loosely. It refers to substrings differing at some number or fewer characters when compared index by index. For example, ‘abc’ and ‘adc’ differ in one position, ‘aab’ and

Stone Game

Cerinta completa Alice and Bob are playing the game of Nim with piles of stones with sizes . If Alice plays first, she loses if and only if the ‘xor sum’ (or ‘Nim sum’) of the piles is zero, i.e.,

String Transmission

Cerinta completa Bob has received a binary string of length N transmitted by Alice. He knows that due to errors in transmission, up to K bits might have been corrupted (and hence flipped). However, he also knows that the string

Sherlock and The Beast

Cerinta completa Sherlock Holmes suspects his archenemy Professor Moriarty is once again plotting something diabolical. Sherlock’s companion, Dr. Watson, suggests Moriarty may be responsible for MI6’s recent issues with their supercomputer, The Beast. Shortly after resolving to investigate, Sherlock receives

Savita And Friends

Cerinta completa After completing her final semester, Savita is back home. She is excited to meet all her friends. Her friends live in different houses spread across the city. There are roads connecting the houses. The road network formed is

Square Subsequences

Cerinta completa Square Subsequences A string is called a square string if it can be obtained by concatenating two copies of the same string. For example, “abab”, “aa” are square strings, while “aaa”, “abba” are not. Given a string, how

Stone Division

Cerinta completa Consider the following game: There are two players, First and Second, sitting in front of a pile of stones. First always plays first. There is a set, , of distinct integers defined as . The players move in