There’s an easier way with no markup changes and minimal CSS. Live demo/fiddle here, code below:
<ul>
<li>1a</li><li>2a</li><li>3a</li><li>4a</li><li>5a</li><li>6a</li>
</ul>
ul {
list-style: none;
margin: 0;
padding: 0;
text-align: right;
}
li {
float: left;
}
li:nth-last-child(1), li:nth-last-child(2), li:nth-last-child(3) {
float: none;
display: inline-block;
}