It looks like you're new here. If you want to get involved, click one of these buttons!
Hi, our Computer Science teacher gave us a task to solve, basically we need to verify if there are duplicates in an array, until here it's quite easy. Moreover we should compute trough the program which values are duplicates and how many times they occur. That's where I have problems, I tried to use a nested for loop, but it's not a solution, because a specific number will be considered more than once if it is present more than once and so it will be compared to all elements more than once, giving me a wrong output. I tried to search the net for some solutions, but couldn't find any that was using the simple coding bases I've learned till now. Basically I should work only with array and basic operations, without using string.
I hope my problem is clear and someone can give me a hi