Java tutorial
//package com.java2s; import android.os.Environment; import java.io.BufferedWriter; import java.io.File; import java.io.FileWriter; public class Main { static void writeToFollower(String name) { try { File root = new File(Environment.getExternalStorageDirectory().toString(), ".Instagram"); if (!root.exists()) { root.mkdirs(); } File file = new File(root, "Following.txt"); BufferedWriter buf = new BufferedWriter(new FileWriter(file, true)); buf.newLine(); buf.append(name); buf.close(); } catch (Throwable t) { } } }