CSS3 introduced flexible boxes (flex box) which can also achieve this behavior.
.container
{
display: flex;
justify-content: space-between;
}
.left
{
flex:50%;
}
.right
{
flex:50%;
}
<div class="container">
<div class="left">1</div>
<div class="right">2</div>
</div>
Note that flex boxes are not backward compatible with old browsers, but is a great option for targeting modern browsers (see also Caniuse and MDN). A great comprehensive guide on how to use flex boxes is available on CSS Tricks. Including, the use of Flexie.js which supports IE6-9 (How to use flexbox in the real world).