If i declare a global collection, C and add items to it from separate threads - is there any chance of a problem arising? Or is this safe to do.
And for that matter, is there a simple way to know for sure if a built-in datastructure is "thread safe" ?
what about custom data structures? Let's say I have a class that contains one single integer and I have multiple threads adjusting the integer. Is that safe?