If you want to log program state during debugging, use non-suspending breakpoints. Select the expression that you want to log, hold Shift, and click the gutter at the line where the expression should be logged.

In the example, 1080 * (HoursElapsed % 24) + PartsElapsed % 1080 will be logged upon reaching line 54.