Pregunta de entrevista de Fannie May Chocolate

DS, Competitive programming, Pattern based questions, time complexity