so I need help with the ¨if else¨ statement in the programming any help?
You may wish to work through some of the programming examples in our “cortex video trainer”
http://www.education.rec.ri.cmu.edu/products/cortex_video_trainer/index.html
The general structure of a conditional statement is like this.
task main()
{
while(1)
{
// this example checks a touch sensor
if( SensorValue touch ] == 1 )
{
// do something for the true condition
}
else
{
// else do something for the false condition
}
// More code
}
}