Two Strings Game Hackerrank Solution For Dynamic Array