Thanks for drip-feeding me with ideas for using IML instead of SQL and the DATA step. With the amount of memory we usually have, IML is applicable to many problems which are not "classical" matrix maths.

Does the loop really have to end?

/* Had you considered: */
DO WHILE (ideas > 0);
SHOW MEMORY;
END;
/* Or perhaps: */
DO UNTIL (inspiration = 0);
PRINT thoughts;
END;