Amazon Interview Question

Write the querySelectorAll method in JS