Critisism needed on coding for multiple if statements.

So I've been experimenting with multiple " if " statements and I was wondering if there might be a simpler way to approach this or if this is the best way to go about it.
This is all hooked up to a single LED and two buttons. Each button makes it behave differently. This does work but it would be nice to be informed of a better way to do this.

int led = 13;
int button = 7;
int putton = 4;
int val = 0;
int con = 0;

void setup()
{
pinMode(led, OUTPUT);
pinMode(button, INPUT);
pinMode(putton, INPUT);
}

//*********************************************************************
void loop()
{
val = digitalRead(button);
con = digitalRead(putton);
if (val == HIGH)
{
digitalWrite(led, LOW);
delay(120);
}

if (con == HIGH)
{
digitalWrite(led, LOW);
delay(60);
digitalWrite(led, HIGH);
delay(60);
}

else
{
digitalWrite(led, HIGH);
}
}

Please read this:-
How to use this forum
It will tell you how to post code. Basically use the </> icon not the quote icon.

This does work but it would be nice to be informed of a better way to do this.

Looks good to me as far as the ifs go.

However your use of delay will become restrictive especially if they get bigger. The line delay( 120 ) is not really doing anything but preventing you from looking at the next condition.

So for real flexibility you need a state machine.
See my
http://www.thebox.myzen.co.uk/Tutorial/State_Machine.html
Or Robin2's several things at once
http://forum.arduino.cc/index.php?topic=223286.0

Thanks for the info! :smiley: (P.S. Sorry for taking so long to reply.)