
Julia 1.0 Programming Cookbook
By :

In simple workflows, users often use the print family of functions to report the state of their programs, for example, for debugging purposes. However, in Julia 1.0, we have built-in functionality enabling diagnostic messages from a program to be handled using custom loggers.
In this recipe, we will explain how you can use loggers to control what is reported by your application. In particular, we will explain how you can add debugging information to your application, yet only enable it on demand.
Now, open your favorite terminal to execute the commands.
In the GitHub repository for this recipe, you will find the commands.txt
file, which contains the presented sequence of shell and Julia commands.
Here is a list of steps to be followed:
Logging
module and then define a function that performs some operations on sets:julia> using Logging julia> function f(x) y = Set(x) for v in x ...