Formatting floating point values as fixed width for printing with "$(value)"?

world-peace
Wed, 18 Dec 2024 18:03:57 +0000
New to Julia

I’m trying to add some logging to an existing codebase.

I am trying to add some timing information to these logs.

Logs are quite simple, they are just println statements wrapped by some functions.

I would like to be able to print floating point values in a fixed width format, so that many lines of logs are relatively easy to read.

Is this possible?

println("$(datetimenow), $(interval), $(logtext))

Here, interval is a floating point value with some timing information.

4 posts - 4 participants