Use console.log instead of document.wirte in examples.