Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public static void main(String[] args) {
- String sCurrentLine;
- int i=1;
- BufferedReader br = null;
- Writer writer = null;
- try {
- String myDocumentPath = System.getProperty("user.home") + "\\Documents"+ "\\iMacros" + "\\Macros";
- String code="";
- writer = new BufferedWriter(new OutputStreamWriter(
- new FileOutputStream(myDocumentPath+File.separator+"usernames1.txt"), "utf-8"));
- br = new BufferedReader(new FileReader(myDocumentPath+"\\list.txt"));
- while ((sCurrentLine = br.readLine()) != null) {
- if(i % 4 == 0)
- {
- writer.write(code+"\n");
- System.out.print(code);
- code="";
- i++;
- }
- else
- {
- code=code+"@"+sCurrentLine+" ";
- i++;
- }
- }
- } catch (IOException e) {
- e.printStackTrace();
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement