Hi,
You have written
if (name.equalsIgnoreCase ("Ryan"))
{System.out.println ("Do the following.");}
if (name.equalsIgnoreCase ("Sarah"))
{System.out.println ("Do this.");}
else
{System.out.println ("Please come back later.");}
The 2 if statements are different and only one else you have written, that to second if.Because of this once the first if gets executed and prints the statement with in it as ithe condition satisfied and also it checks the next if, there the conditoin fails and it prints the corresponding else statement.
To avoid this you can write your code as follows :
if (name.equalsIgnoreCase ("Ryan"))
{System.out.println ("Do the following.");}
else if (name.equalsIgnoreCase ("Sarah"))
{System.out.println ("Do this.");}
else
{System.out.println ("Please come back later.");}
Thanks & Regards
Divakara