Sha256: 2cceff47cb80a9e457005c3a39388950f4973fbe63da2657cad9308efc50f73d
Contents?: true
Size: 431 Bytes
Versions: 30
Compression:
Stored size: 431 Bytes
Contents
Testing out some functions here... .func myfunc "Eureka!" .end I am calling $$myfunc here... Let's see what happens. Functions can take a parameter in brackets (which it can parse itself as needed): .func mean list = param.split(",").map(&:to_f) sum = list.inject(0, :+) avg = sum / list.size.to_f avg.to_s .end The result is $$mean[1,2,3,4,5,6,7] as I see it. Some functions like date and time are predefined.
Version data entries
30 entries across 30 versions & 1 rubygems