Why doesn't this work?
public class
testing {
public static void main(
String args[] )
{
String stringInput = args[0];
if( stringInput == "thisone")
{
System.out.print(stringInput);
}
}
}
it compiles ok
but when run like this:
java testing thisone
it doesn't give the expected output. It never enters the if statement. If I output the value of thisone to the screen it displays properly.