This code is equivalent to this:
int a = 2 ;
int b = a + 1 ;
First expression to the left of comma gets evaluated, then the one to its right. The result of the right most expression is stored in the variable to the left of =
sign.
Look up the comma operator for more details.
http://en.wikipedia.org/wiki/Comma_operator