Here you can find the source of getRandomCharacter()
private static char getRandomCharacter()
//package com.java2s; //License from project: Open Source License import java.util.Random; public class Main { private static Random rnd = new Random(); private static char getRandomCharacter() { char c = (char) (rnd.nextInt(26) + 'a'); return c; }/*from www.j a v a2 s .co m*/ }