Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import java.util.ArrayList;
- import java.util.Scanner;
- public class DailyProgrammerOblique {
- private static int i;
- public static void main(String args[]){
- Scanner scanner = new Scanner(System.in);
- ArrayList<Integer> intList = new ArrayList<Integer>();
- while(scanner.hasNextInt()){
- int number = scanner.nextInt();
- intList.add(number);
- }
- int[] numList = new int[intList.size()];
- for(i=0; i<intList.size(); i++){
- numList[i] = intList.get(i);
- }
- for(i=1;i<5;i++){
- for(i=0;i<numList.length;i++){
- for(i=0;i<numList.length;i++){
- System.out.println(numList[i]);
- }
- }
- }
- }
- }
- /*
- use scanner to get inputs
- create a new array based on the now known length
- put each integer into the array with place of [i]
- */
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement