public static final String toBinaryString(int l,int L){
  String sb=new String(Integer.toBinaryString(l));
  while (sb.length() < L) {
    sb="0" + sb;
  }
  return sb;
}

public static final String toBinaryString ( int l , int L ) { String sb = new String ( Integer . toBinaryString ( l ) ) ; while ( sb . length ( ) < L ) { sb = "0" + sb ; } return sb ; }
tobinarystring - use to go through all ' l ' binary combinations .
