Pergunta de entrevista da empresa Folio3

Swap 2 numbers without any third variable .

Resposta da entrevista

Sigiloso

5 de mai. de 2021

In JavaScript we can you use array destructing to do that. let a = 2 let b = 3 [ a, b ] = [ b, a ] Now, a = 3, b = 2