Untitled

                Never    
Java
       
import java.util.Scanner;
public class main3 {
    public static void main(String[] args) {
 //   2.א.4   
// get the input from user        
        Scanner s = new Scanner(System.in);
        System.out.println("please enter 3 digit number");
        int num = s.nextInt();
        boolean isEqul =false;
        int temp = num;
//loop that checks if == and devid the num by 10 to get the next digit- return boolean        
        for (int i = 0;i<3;i++){
                if (temp%10==temp/10){
                isEqul=true;
            }
                temp=temp/10;
        }
// usung a string var to get the condition nice and clean in print        
        String printRes =isEqul ? "all digits the same" : "the digits are difrrent";
        System.out.println(printRes);
    }
}

Raw Text