// "Introduce new StringBuilder to update variable 's'" "true-preview"

public class Main {
    void test(boolean b) {
        String s = "";
        if (b)
            for(int i=0; i<10; i++) {
                if(s.indexOf("a") > 0) {
                    System.out.println(s);
                    break;
                }
                s+<caret>=i;
            }
        s = s.trim();
        System.out.println(s);
    }
}