In your Server code, you are writing your answer to the socket itself.
You have two choices:
1. display the message on the server using
System.out.println("Hello " + inputLine + " from Gary");
2. read the answer on the client and display it in a widget of your Activity.
You have to check for available data in the input stream, read the data, and convert to string before setting the text of the "display" widget (for example)