Tag Archives: Week of Code 32 Solution

HackerRank : Week of Code 32 – Fight the Monsters

Fight the Monsters : Hackerrank Fight the Monsters – Jason is trapped in a forest with hungry monsters and must use his trusty blaster to defend himself! Each monster has a health value, . Jason can discharge his blaster at a monster once per second and reduce its health points by units. Once a monster’s health points become… Read More »

HackerRank : Week of Code 32 – Duplication

Duplication : Hackerrank Consider a binary string, s, with an initial value of “0” . We expand s by performing the following steps: Create a string, t, where each character ti  is equal to 1- si. For example, if s=”01″ , then t=”10″. Note that t and s always have the same length because t is the complement of s. Append t to the end of… Read More »