Lets say you have an array that is rendered in a ul with an li for each element and a property on the controller called selectedIndex.
ul
li
selectedIndex
Ternary operator has just been added to angular parser in 1.1.5.
So the simplest way to do this is now :
ng:class="($index==selectedIndex)? 'selected' : ''"