Counting repeated elements in an integer array

前端 未结 13 1302
挽巷
挽巷 2020-11-27 08:02

I have an integer array crr_array and I want to count elements, which occur repeatedly. First, I read the size of the array and initialize it with numbers read

13条回答
  •  再見小時候
    2020-11-27 08:27

    public class FindRepeatedNumbers 
    {
     public static void main(String[] args) 
        {
         int num[]={1,3,2,4,1,2,4,6,7,5};
               Arrays.sort(num);
    
      for(int j=1;j

提交回复
热议问题