Question d’entretien chez Evolent

Explain how to write this process in Java.