The Print
function is primarily used as a debugging tool. There are generally much better ways to get output if that's your goal in a given situation. One way is to put the relevant data into a data structure--a List
for example--and then output that at the end.
But. let's take your simple example and try to do what you want using a better tool: CellPrint
along with TextCell
(or you could use ExpressionCell
if that's what is more pertinent). Try this: it CellPrint
s in the "Output" CellStyle
since that is what the TextCell
's CellStyle
is set as:
TestF[t_] :=
Module[{t0}, CellPrint[TextCell[{t, t + 1, t + 2}, "Output"]];
t0 = t + 1]