Thread: output
View Single Post
  #3 (permalink)  
Old 12-01-2007, 11:28 PM
hardwired hardwired is offline
Senior Member
 
Join Date: Jul 2007
Posts: 1,022
hardwired is on a distinguished road
Code:
PrintWriter pw = new PrintWriter("testOutput.txt"); String[] strs = { "hello", "world", "", "circus" }; for(int j = 0; j < strs.length; j++) { if(!strs[j].equals("")) pw.println(strs[j]); } pw.close();
Reply With Quote