Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public class Solution
- {
- public static void main(String[] args) {
- readData();
- }
- public static void readData() {
- BufferedReader reader = new BufferedReader (new InputStreamReader(System.in));
- ArrayList list = new ArrayList();
- try{
- while (true){
- String fig = reader.readLine();
- int nFig = Integer.parseInt(fig);
- list.add(nFig);
- }
- }
- catch (Exception e){
- for (int i = 0; i < list.length; i++){
- System.out.println (i);
- }
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement