explain if else statement with example in r programming