//First block of code
for (let i = 0; i < nodesData.length; i += 2) { const currentSource = nodesData[i]; const currentTarget = nodesData[i + 1]; const