← 返回 google 的题目列表Largest Group by Digit
类型:online_judge
Given an array of N two-digit integers (10-99). Two numbers can form a group if they share at least one common digit. In each number, each digit is counted only once. Determine the size of the largest group.
Input:
An integer array of length up to $10^5$, where each element is a two-digit number.
Output:
An integer representing the size of the largest group.
Example
Input
52 28 22 35 33