Understanding how console.log works