CodeChef submission 176914 (JAVA) plaintext list. Status: WA, problem TEST, contest . By sidz8690 (sidz8690), 2010-02-01 08:09:15.
import java.io.*; import java.util.ArrayList; public class Main { ArrayList<String> al=new ArrayList<String>(); al.add(str); while(!str.equals("42")) { str=in.readLine(); al.add(str); if(str.equals("42")) { }}}}}


can someone tell me why is my
can someone tell me why is my solution wrong ??
Should you always be adding
Should you always be adding the first number to al?
In fact, you shouldn't even be using an ArrayList at all, just print out the numbers when you read them.
hmm..thanks!!
hmm..thanks!!