URI Problem (Divisors I) 1157:
Divisors I is a basic problem on URI online judge for novice problem solver.
You can find details on this Link.
import java.util.Scanner; /** * @Author : Muhammad Harun-Or-Roshid * @Date : Oct 21, 2016 * @Time : 11:06:28 PM */ public class Uri1157 { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int n = sc.nextInt(); for (int i = 1; i <= n; i++) { if(n%i==0){ System.out.println(i); } } } }