Java recursion sum of number non divisible by specific number <p>I have to find sum of the all even numbers that are not divisible by 7 using recursion. I tried this code but it seems I am making mistake somewhere because it returns 0: </p> <pre><code>public static void main(String[] args) { System.out.println(specialSum(50)); } public static int specialSum(int a) { if ((a &gt;= 1) &amp;&amp; ((specialSum(a-1))%7 !=0)) { return a + specialSum(a -1); } else{ return 0; } } } </code></pre>