Problem 1512 · Easy

Number of Good Pairs

Count equal pairs by recording how many times each value has already appeared as each new value arrives. The visual shows a counter rising as matching pairs form.

Open the interactive visualisation