URI Problem 1070 Solution in Java
Problem Details Link
Solution:
Solution:
import java.util.Scanner;
import java.util.Scanner;
/**
* @Author : Muhammad Harun-Or-Roshid
* @E-mail : md.parvez28@gmail.com
* @Date : Oct 14, 2016
* @Time : 9:36:31 PM
*/
public class Uri1070 {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int x = sc.nextInt();
int count = 0;
if (x > 0) {
while (count < 6) {
if (x % 2 != 0) {
count++;
System.out.println(x);
}
x++;
}
}
}
}
Comments
Post a Comment