sqrt 平方根

# --- sqrt
{
  n lset : base lset
  { 0 } %n 0 = if
  1 v lset
  { %v %base * v lset } 1 %n i for
  %v
} sqrt set
# --- test
2 3 sqrt! .

再帰を使う方法:

#--- sqrt
{
  v lset : n lset : base lset
  { %v : exit } %n 0 <= if
  %v %base * v lset
  n dec
  %base %n %v sqrt!
} sqrt set
#--- test
2 3 1 sqrt! .