int pb = 7; //push button pin 7
pb=digitalRead(7); //pb = pushbutton state high or low
So, is pb a pin number or a state? Get your story straight.
How IS your switch wired? Using the internal pullup resistor makes wiring the switch so much easier. One leg to the digital pint; the other leg to ground.