Hi everyone!

I want to create a dummy variable such that it gives me 1 when either one or both of the other two dummy variables are 1. So, for example, I know that in order to get this dummy to return 1 in the hypothetical case in which I needed both these conditions to occur, I could have just written gen 18yroldMale = ((male==1) & (age==18)). So this command would generate me a variable called 18yroldMale that returns 1 in the case the individual is BOTH a male AND is 18 years old. But what if I wanted it to return 1 even in the case in which just one or both of the conditions were met (when either it's a male no matter the age, or an 18 yr old individual no matter the sex, or both)? I tried replacing the "&" with an "or", but stata gives me error in that case.

Thank you in advance! Please help