I apologize in advance if this is an old question, but I have not been able to uncover it in my searches.
I have written a program which simulates plant population dynamics in a spatial grid. I would like it to output annual population statistics; however, I would like the program to be felxible enough to determine the output filenames at run time by concatenating:
a) a user-defined base string (e.g. "year")
b) the integer value of time from the program's internal clock (e.g. 1)
c) a predefined string representing the appropriate output file extension (e.g. ".txt")
In this example the resulting filename, determined during the run, would be "year1.txt".
I can not figure out how to convert the value of the integer variable "Time" into a string variable so that I can easily combine it with the other string variables. Text and web searches have come up blank. I hope someone can help me out, and thank you in advance for your advice!