nix functions

the basics let f = arg : arg + 1 ; in f 5 # evaluates to 6 Basic function syntax is simple, we provide one argument and get one output, and a function can only have one input and output. But what if we wanted multiple armament? multiple arguments let add = num_1 : num_2 : num_1 + num_2 ; in add 1 3 # evaluates to 4 Here add can take in 2 numbers num_1 and num_2 and return the result of adding…