Pergunta de entrevista da empresa Ixigo.com

How JavaScript works as a single thread?