I fixed it again by instead of using num unlocked using unlocked.count and locked.count.
Topic:
Programming Languages
SubTopic:
Swift
Tags: