Which element is returned by document.getElementById?

1st element w. id="test"
2nd element w. id="test"
3rd element w. id="test"