Using bitRead to toggle between LEDs
To toggle LED you can do:

uint8_t BITval=1; //initialization B00000001

void toggle()
{
 digitalWrite(RED_pin,BITval&amp;1);    //Bxxxxxxx1
 digitalWrite(BLUE_pin,BITval&amp;2);   //Bxxxxxx1x
 digitalWrite(GREEN_pin,BITval&amp;4); //Bxxxxx1xx

 BITval=BITval&lt;&lt;1;
 if (BITval== B00010000) //reset BIT value
    BITval=1;
}


And assuming you want to do bitRead() to read input from active-low push button which is connected to PORT-x, PIN-y

you can do:

if (bitRead(PORTx,PINy))==0) 
toggle();