Question d’entretien chez Amazon

Basic C code algorithm, need to write it down, not typing