Middle+
Is it possible to create new instances of a class while a static synchronized method is executing?
sobes.tech AI
Answer from AI
Yes, it is possible. The synchronized static modifier blocks access to the class, not its instances. While one thread executes a static synchronized method, other threads cannot execute other static synchronized methods of the same class. At the same time, creating new instances of the class and calling non-static methods of these instances are possible from other threads.