const target = document.getElementById('main');
console.log(target);

// console.log(document);
// console.log(window.document);
// console.log(window);

// alert('アラートが表示されます');


// console.log(document.getElementsByTagName('p'));


// const target = document.getElementById('main');
// const parent = target.parentNode;
// console.log(parent);



// const target = document.getElementById('main');
// const first = target.firstElementChild;
// const last = target.lastElementChild;
// const children = target.children;
// console.log(first);
// console.log(last);
// console.log(children);



// const target = document.getElementById('main');
// const next = target.nextElementSibling;
// const previous = target.previousElementSibling;
// console.log(next);
// console.log(previous);


// const targets = document.querySelectorAll('#main > p');
// const target = document.querySelector('#main > p');
// console.log(targets);
// console.log(target);