#Z13109. 判断能否被3,5,7整除
判断能否被3,5,7整除
Description
Given an integer, determine whether it is divisible by 3, 5, and 7, and output the following information:
- If it is divisible by 3, 5, and 7 simultaneously (output
3 5 7, with a space between each number); - If it is divisible by only two of the numbers (output the two numbers in ascending order, e.g.,
3 5or3 7or5 7, separated by a space); - If it is divisible by only one of the numbers (output that divisor);
- If it is not divisible by any of the numbers, output the lowercase character
'n'(without the single quotes).
Input Format
Input one line containing an integer.
Output Format
Output one line indicating the divisibility of the integer by 3, 5, and 7 as per the description.
105
3 5 7