incremental dimming [noob to programming]

thanks for the reply. Scope issues are gone. you can probably see I am very new to this. Is this what you meant by assigning a value to up? I appreciate you don't want to write my code for me but can you give a clue on the braces? I will of course re-read the basics.

int increment = 30;
int val;
int up = LOW;
int lastval = 5;
const int upPin = 3;
const int downPin = 4;
const int Mosfet = 11;

void setup (){
pinMode(3, INPUT);
pinMode(4, INPUT);
pinMode(13, OUTPUT);
Serial.begin(9600);

int up = digitalRead(upPin);

}
void loop(){
if (up == HIGH) val = lastval + increment;
(lastval = val);
digitalWrite(Mosfet, val);
Serial.println(val);
if (up == LOW) val = lastval;
(lastval = val);
digitalWrite(Mosfet, val);
Serial.println(val);
delay(5);
}