#!/usr/bin/ruby

var angle_deg = 45;
var angle_rad = Num.pi/4;

for arr in [
    [sin(angle_rad), sin(deg2rad(angle_deg))],
    [cos(angle_rad), cos(deg2rad(angle_deg))],
    [tan(angle_rad), tan(deg2rad(angle_deg))],
    [cot(angle_rad), cot(deg2rad(angle_deg))],
] {
    say arr.join(" ");
}

for n in [
    asin(sin(angle_rad)),
    acos(cos(angle_rad)),
    atan(tan(angle_rad)),
    acot(cot(angle_rad)),
] {
    say [n, rad2deg(n)].join(' ');
}

var a = 3
var b = 4

say [a, b].sum
[a,b].sum == 7 || die "error"

say %i(1 2 3).sum
%n(1 2 3).sum == 6 || die "error"
