It's a simple bit of PHP that should give a totally random 50:50 split, although there might be some effect with your browser caching the page. Don't forget that "left,right,left,right" is just as (un)likely as "left,left,left,left" or "right,right,left,left" or indeed any other sequence of (in this case four) sides.*
However, the main idea is that if visitors read several of the articles on the site, the ads should appear pretty much randomly on different sides of the articles, because the browser-caching effect won't be there with different article pages.
* The winning lottery-number sequence 1,2,3,4,5,6 is just as likely to come up as 31,17,6,43,12,23 or any other particular sequence of six numbers that you might specify.

Bookmarks