You have already been told not to create multiple threads for the same question. You now have three threads for the same question. You have been directed to information that will help you build a counter. We like to help people but we don't just design things for them. we expect them to make some effort themselves.