Im trying to make a tax program and for some reason if the income is < 100000 everything works fine but as soon as its more than that it gives me the wrong answer. It reads the first if statement then if its false goes to the 2nd but if income > 100000 it doesnt go to the next if but instead just goes straight to the output.
This is always going to be true because every number is either greater than 50000 OR less than 75000. You probably meant &&
But you shouldn't be using && either. Let else do the work for you here. If you do an 'else', you know the previous 'if' condition is false. Therefore...
1 2 3 4
if(income <= 50000)
...
elseif(income <= 75000) // <- don't check > 50000, we already know the
// income is > 50000 because of the 'else' here.