Pregunta de entrevista de Global Payments

debug the code given by them