package ru.matevosyan;

/**
 * Created BiggerRepeatValue fo finding bigger repeating number in array.
 * Created on 25.01.2017.
 * @since 1.0
 * @author Matevosyan Vardan
 * @version 1.0
 */

public class BiggerRepeatValue {

    /**
     * Create to find bigger repeating value.
     * @param intNumbers array with which we find bigger number
     * @return <code>maxCount</code>
     */

    public int findRepeatValues(int[] intNumbers) {
        int countFor = 0;
        int maxCount = 0;
        int number = 0;

        for (int i = 0; i < intNumbers.length - 1; i++) {

            if (intNumbers[i] == intNumbers[i + 1]) {
                countFor++;
                if (maxCount < countFor) {
                    maxCount = countFor;
                    number = intNumbers[i];
                }

            } else {
                countFor = 0;
            }
        }
        System.out.println("Number" + number + "repeat" + maxCount + "times");
        return maxCount;
    }
}

@@ -903,18 +903,17 @@
 rint
-ln
+f
 (%22Number
 %22 + 
@@ -912,50 +912,52 @@
 mber
-%22 + number + %22repeat%22 + maxCount + %22times%22
+ %25d is repeating %25d times%22, number, maxCount
 );%0A 

change outputing format from println tp printf