auto objects = std::vector<Object>();for(auto& obj : objects) {...} // here i can modify obj (move, remove etc)for(auto obj : objects) {...} // here i can't move/delete obj from objects
auto objects = std::vector<Object>();for(auto& obj : objects) {...} // here i can modify obj (move, remove etc)for(auto obj : objects) {...} // here i can't move/delete obj from objects
From what i know, in C# this doesn t allow me to remove, move, modify objects.
var objects = new List<Object>();foreach(var obj in objects) {...}
var objects = new List<Object>();foreach(var obj in objects) {...}