CastleLab / COMP3021-2020Fall-PA3-Student-Version

HKUST - COMP3021 - 2020Fall - Programming Assignment 3 - Student Version
https://course.cse.ust.hk/comp3021/
Apache License 2.0
1 stars 0 forks source link

About "synchronized" key word #18

Closed wuto-chai closed 3 years ago

wuto-chai commented 3 years ago

noticed that there is "synchronized" modifier in Knight's getCandidateMove but no in Archer's. Are we supposed to implement implicit lock for Knight and explicit lock for Archer? or can we add "synchronized" in Archer or delete it in Knight?

Troublor commented 3 years ago

You can delete or add synchronized modifier as you wish. It doesn't matter.

wuto-chai commented 3 years ago

what about add it in other methods?

Troublor commented 3 years ago

Yes you can add synchronized to other methods as well.

wuto-chai commented 3 years ago

thanks!