import java.util.*; public class BurrowsWheelerTransform { public static void main(String[] args){ String input = "2\nUAEACM\nBurrows-Wheeler Transform"; Scanner s = new Scanner( input); int cases = Integer.parseInt(s.nextLine()); for(int i=0;i cyclicShifts = new ArrayList(); cyclicShifts.add(kw.toString()); for(int i=0;i