my goal was to remove an item from a list while the code was running.

in the larger scope this is a gateway to morphing running code, maximizing efficacy, evolving code as well as automatic programming and compiling code.

moreover it's about gaining command prompt abilities for running code.

normally removing list items from a loop that is going through that very list is an error raiser, crush event for the program.

see how I went around it:


        ArrayList<String> tl = new ArrayList<>();
        int c = 0;
        try {
            for (int i = 0; i < tl.size(); i++) {
                if (c == 3){
        catch(Exception e) {
            for (int i = c; i < tl.size(); i++) {

apart from the removed element, all the list was looped through. king