So I have this Java assignment, where I must create a program, where if the user enters "initiate" it begins the for loop, which will print "initiated" 100 times. I've searched my code for errors, but can't find any. Please help :)
Thanks in advance.
       package container;
        import java.util.Scanner;
        public class Assignment1 {
    public static void main(String[] args) {
        // TODO Auto-generated method stub
        int x = 0;
        String checker = "initiate";
        Scanner scan = new Scanner(System.in);
        String input = scan.nextLine();     
        if(input == checker){
            for(x=0;x<=100;x++){
                System.out.println("Initiated");
            }
        }   
    }
}
 
     
     
     
     
     
    