Find the majority of n elements using the partitioning method
1.0
The design idea of this algorithm for finding the majority of elements (called the main element in some places) comes from quick sort. First, use the quick sort method to find the median of these n elements. Then, you can find the main element (if these n If each element has a main element).
The compressed package includes: source code, executable files, and design reports.