/* Predicate function that checks wether a positive integer is arithmetic or not */ arith_nump(n):=block(listify(divisors(n)),apply("+",%%)/length(%%),if integerp(%%) then true)$ /* Function that returns a list of the first len arithmetic numbers */ arith_num_count(len):=block( [i:1,count:0,result:[]], while count