#K411. Divisibility Checking
Divisibility Checking
Divisibility Checking
Given two integers a
and b
, determine whether a
is divisible by b
. In other words, check if the remainder when a
is divided by b
is zero. Formally, a is divisible by b if and only if \(a \mod b = 0\).
The program should read the input from standard input (stdin) and write the output to standard output (stdout). The output should be the string "divisible" if a
is divisible by b
, otherwise it should output "not divisible".
inputFormat
The input consists of two space-separated integers a
and b
provided in a single line from stdin. It is guaranteed that b
is non-zero.
outputFormat
Output a single line from stdout containing the string "divisible" if a
is divisible by b
, otherwise output "not divisible".
10 5
divisible