I have to lists of data, one with id of dates and other one with id of nums.
The number of letters in date and num is not equal so how Can I put each of divs in nums be exactly under dates?
#dates div{
display: inline-block;
margin-left: 20px;
}
#nums div{
display: inline-block;
margin: 30px;
position: relative;
top:-20px;
}
<body>
<div id="dates">
<div>Aug 5</div>
<div>Aug 6</div>
<div>Aug 7</div>
<div>September 12</div>
</div>
<div id="nums">
<div>9</div>
<div>7</div>
<div>5</div>
<div>3</div>
</div>
</body>
For example, in here 3 should go to right because it should be exactly down of the middle of september.
I don't need pixel things like margin and left and right. because the nums may change but it must still be in the down of middle of it's date.
Thanks