Module: (Java) Subroutines: procedures and functions - 1


Problem

11/11

All divisors of a number

Problem

Write a procedure that displays all the divisors of N in one line separated by a space.
Using this procedure, write a program that for all entered natural numbers (numbers are entered up to 0, 0 is a sign of the end of input) displays the divisors of the current number
Examples
# Input Output
1 10
5
6
0
1 2 5 10
15
1 2 3 6