so when i press the push button it should go to DEC1, else it should go to LEDSEL
is my program right???
and do i need to add a delay in between?? if so how much???
Your code is not compelete, from what I see, it will run only once and doesn't loop.
Depends on your application, use an interrupt and connect the button to the interrupt pin, or use a loop (resource hogger) if you're connecting it to an IO pin.
Otherwise your code is ok.