Android examples for java.lang:String Split
split string Equally
import java.util.ArrayList; import java.util.List; public class Main{ public static List<String> splitEqually(String text, int size) { List<String> ret = new ArrayList<String>((text.length() + size - 1) / size);//from www .ja v a2 s . c o m for (int start = 0; start < text.length(); start += size) { ret.add(text.substring(start, Math.min(text.length(), start + size))); } return ret; } }