About Question enthuware.ocpjp.v7.2.1483 :
Moderator: admin
About Question enthuware.ocpjp.v7.2.1483 :
is wrong, for me to compile and run without any problems, the result is 10
-
- Site Admin
- Posts: 10388
- Joined: Fri Sep 10, 2010 9:26 pm
- Contact:
Re: About Question enthuware.ocpjp.v7.2.1483 :
As explained in the explanation, it is not possible to determine which thread will run first. So even if you get 10 every time you run it, you cannot rely on this fact that it will always print 10.
HTH,
Paul.
HTH,
Paul.
-
- Posts: 30
- Joined: Tue Mar 24, 2015 2:59 pm
- Contact:
Re: About Question enthuware.ocpjp.v7.2.1483 :
Hi Paul.
Could you explain what does it mean volatile modifier and how it influnce output.
Could you explain what does it mean volatile modifier and how it influnce output.
-
- Site Admin
- Posts: 10388
- Joined: Fri Sep 10, 2010 9:26 pm
- Contact:
Who is online
Users browsing this forum: No registered users and 3 guests