Can anyone help me convert this code to make it run recursively? I'm not exactly sure how. The goal of the code is to count the amount of numbers in an array are divisible by k.
int[] a = {1,2,3,4,5,6,9}
int k = 3;
int count;
for (int i = 0;i <a.length; i ++){
if (a[i] % 3 == 0){
count ++;
}
}
return count;