A music analyst is studying the performance history of singers to discover which roles are frequently performed by the same artist within a short span of years.
You are given a list of performances, where each entry is a three-element list [<singerName>, <roleName>, <yearString>], and an integer period.
Two different roles A and B co-occur if the same singer performed both roles and the absolute difference in their performance years is at most period (inclusive). Each co-occurring pair contributes one count to A's relationship with B and one count to B's relationship with A. If multiple singers independently perform the same pair of roles within the period, each singer's contribution is counted separately.
Return a list of rows representing all co-occurrence relationships. Each row is a three-element list [<roleName>, <cooccurringRoleName>, <countString>], where countString is the co-occurrence count as a decimal string.
