package leetcode;

/**
 * https://leetcode.com/problems/rabbits-in-forest/
 */
public class Problem781 {
    public int numRabbits(int[] answers) {
        // TODO
        return 0;
    }

    public static void main(String[] args) {
        Problem781 prob = new Problem781();
        System.out.println(prob.numRabbits(new int[]{1, 1, 2})); // 5
        System.out.println(prob.numRabbits(new int[]{10, 10, 10})); // 11
        System.out.println(prob.numRabbits(new int[]{})); // 0
    }
}

@@ -478,16 +478,834 @@
 ); // 0%0A
+        System.out.println(prob.numRabbits(new int%5B%5D%7B1, 0, 1, 0, 0%7D)); // 5%0A        System.out.println(prob.numRabbits(new int%5B%5D%7B1, 2, 3%7D)); // 9%0A        System.out.println(prob.numRabbits(new int%5B%5D%7B1, 2, 2, 3%7D)); // 9%0A        System.out.println(prob.numRabbits(new int%5B%5D%7B1, 2, 2, 2, 3%7D)); // 9%0A        System.out.println(prob.numRabbits(new int%5B%5D%7B1, 2, 2, 2, 2, 3%7D)); // 12%0A        System.out.println(prob.numRabbits(new int%5B%5D%7B1, 2, 2, 2, 2, 2, 3%7D)); // 12%0A        System.out.println(prob.numRabbits(new int%5B%5D%7B1, 2, 2, 2, 2, 2, 2, 3%7D)); // 15%0A        System.out.println(prob.numRabbits(new int%5B%5D%7B0%7D)); // 1%0A        System.out.println(prob.numRabbits(new int%5B%5D%7B0, 0%7D)); // 2%0A        System.out.println(prob.numRabbits(new int%5B%5D%7B0, 0, 0%7D)); // 3%0A        System.out.println(prob.numRabbits(new int%5B%5D%7B0, 0, 0, 0%7D)); // 4%0A
     %7D%0A%7D%0A

Update problem 781