Code: Select all
class Core {
int x;
//x is a substitute to determine position within a list as it grows
//Main Method
void list_expanding(int primenum)
{
int [] list = new int [];
x = 0;
for (int i = primenum - 1; i > 1; i--) {
if(primenum % i == 0) {
//The problems start here I believe
list[x] = i;
x += 1;
}
//These are here just to control if the values match
// println("Current list content:" + list[x] + " Current base:" + primenum);
// println("Current process number:" + i);
if(i == 2) {
break
}
}
}
}