Is dit jouw bedrijf?
Brain Teaser: Swap two numbers without using a temporary third variable.
Anoniem
a = a+ b b = a - b a = a-b
Example: A=5, B=7 B=B*A^2=7*25 A=B/(A^2)=7*25/25=7 B=sqrt(B/A)=sqrt(7*25/7)=5
I provided a solution involving using multiplication/division to store the information about both numbers in a single variable
Volg de bedrijven van je dromen om als eerste op de hoogte te zijn van vacatures en te profiteren van tips van insiders.
Zoek naar vacatures om gepersonaliseerde vacature-aanbevelingen en -updates te krijgen.