Skip to content

Instantly share code, notes, and snippets.

View andras-gyarmati's full-sized avatar
🐧
Noot noot

Gyarmati András andras-gyarmati

🐧
Noot noot
View GitHub Profile
@andras-gyarmati
andras-gyarmati / remove.txt
Last active January 23, 2018 23:37
processing remove items from arraylist while iterating
void foo() {
if (list.size() > 0) {
boolean finished = false;
int i = 0;
Bar b;
while (!finished) {
b = list.get(i);
if (b.condition == whatever) {
list.remove(b);
} else {