Question d’entretien chez BNP Paribas

Swap 2 numbers without using temp variable. Why Testing.

Réponse à la question d'entretien

Utilisateur anonyme

20 oct. 2018

Let i=20, j=5 If (i>j) { i=i+j so now it is 25 j=i-j so now 20 i=i-j so now 5 Else reverse the variables

9