title: java conditional statement checking
body: <p>I'm in a beginning java course and I have a conditional statement that I'm trying to check without using if/if else statements. I have written it to check for a blank textfield but... it's not working correctly. Here is a copy of the code that I wrote, can anyone please tell me what's wrong?</p>
  
  <pre><code>String nameCheck = (nameField.getText() == "")? "Please enter a name" : "Hello, " + nameField.getText();
  </code></pre>