EPAM Systems interview question

Como funcionam as microtasks e macrotasks do javascript?