let num = parents[i].parentElement.lastElementChild.firstElementChild.getAttribute("data-num"); parents[i].style.left = num + "%";
for(let k=0; k<lines.length; k++){ // ... }
let num = parents[i].parentElement.lastElementChild.firstElementChild.getAttribute("data-num");
let num = parents[i].parentElement.querySelector('line').getAttribute("data-num");
for(let i=0; i<parents.length; i++){ for(let k=0; k<lines.length; k++){ } }