1.6

PHOTO EMBED

Sat Feb 24 2024 11:08:27 GMT+0000 (Coordinated Universal Time)

Saved by @abdul_rehman #java

import java.util.Scanner;

public class Task6{
	public static void main(String args[]){
		
		Scanner input = new Scanner(System.in);
		
		System.out.println("Enter first no: ");
		int num1 = input.nextInt();
		System.out.println("Enter second no: ");
		int num2 = input.nextInt();
		int reminder = num1 % num2;
		System.out.printf("The reminder is: %d\n",reminder);
		if(reminder == 0){
			System.out.printf("%d is divisible by %d",num1,num2);
		}
		else{
			System.out.printf("%d is not divisible by %d",num1,num2);
		}
		
	}
}
content_copyCOPY