I have tried all the ways i can think of to break this loop, but none have worked. I was wondering if anyone can help.
import java.io.*;
import java.util.*;
public class Tester
{
public static void main(String args[])
{
int j;
for(j=5;j>4;j++)
{
Scanner kbReader = new Scanner(System.in);
System.out.print("Type in a sentence and press ENTER. ");
String a = kbReader.next( );
String b = a.toUpperCase();
System.out.println(b);
if( b == "EXIT" )
break;
}
}
}