Hi,
It's about a year that I have been coding on Java but I still have basic problems working with threads. My main concern is that I can't understand the logic they obey in their behaviour. I know that they are processes which run independently but I don't know how to join their results or make them communicate with each other. I also have difficulties working with threads with different priorities mainly related to input-output procedures which never seem to run synchronised with other parts of code. Also taking use of synchronised blocks, does not always lead to a result in which the code inside the block is not interrupted by any other procedure. I'm not convenient with where I should use wait, sleep, join.... It seems like even using these tricks does not work when I want to interrupt a higher priority thread with a lower one. I will be thankful if you could guide me!