diff --git a/prelude.md b/prelude.md index ada9f28..bfb91c4 100644 --- a/prelude.md +++ b/prelude.md @@ -77,7 +77,7 @@ You can see what this looks like in the last clause of `add`: `((x1, y1), (x2, y [assoc?](#assoc)    [bool?](#bool)    [box?](#box)    [coll?](#coll)    [dict?](#dict)    [eq?](#eq)    [fn?](#fn)    [keyword?](#keyword)    [list?](#list)    [neq?](#neq)    [nil?](#nil)    [number?](#number)    [ordered?](#ordered)    [set?](#set)    [show](#show)    [some](#some)    [some?](#some)    [string?](#string)    [tuple?](#tuple)    [type](#type) ## All functions, alphabetically -[abs](#abs)    [add](#add)    [and](#and)    [angle](#angle)    [any?](#any)    [append](#append)    [assert!](#assert)    [assoc](#assoc)    [assoc?](#assoc)    [at](#at)    [atan/2](#atan2)    [back!](#back)    [background!](#background)    [between?](#between)    [bg!](#bg)    [bk!](#bk)    [bool](#bool)    [bool?](#bool)    [box?](#box)    [butlast](#butlast)    [ceil](#ceil)    [chars](#chars)    [clear!](#clear)    [coll?](#coll)    [colors](#colors)    [concat](#concat)    [contains?](#contains)    [cos](#cos)    [count](#count)    [dec](#dec)    [deg/rad](#degrad)    [deg/turn](#degturn)    [dict](#dict)    [dict?](#dict)    [diff](#diff)    [dissoc](#dissoc)    [dist](#dist)    [div](#div)    [div/0](#div0)    [div/safe](#divsafe)    [doc!](#doc)    [downcase](#downcase)    [each!](#each)    [empty?](#empty)    [eq?](#eq)    [err](#err)    [err?](#err)    [even?](#even)    [false?](#false)    [fd!](#fd)    [filter](#filter)    [first](#first)    [floor](#floor)    [fn?](#fn)    [fold](#fold)    [forward!](#forward)    [get](#get)    [goto!](#goto)    [gt?](#gt)    [gte?](#gte)    [heading](#heading)    [heading/vector](#headingvector)    [hideturtle!](#hideturtle)    [home!](#home)    [inc](#inc)    [inv](#inv)    [inv/0](#inv0)    [inv/safe](#invsafe)    [join](#join)    [keep](#keep)    [keys](#keys)    [keyword?](#keyword)    [last](#last)    [left!](#left)    [list](#list)    [list?](#list)    [loadstate!](#loadstate)    [lt!](#lt)    [lt?](#lt)    [lte?](#lte)    [map](#map)    [max](#max)    [min](#min)    [mod](#mod)    [mod/0](#mod0)    [mod/safe](#modsafe)    [mult](#mult)    [neg](#neg)    [neg?](#neg)    [neq?](#neq)    [nil?](#nil)    [not](#not)    [odd?](#odd)    [ok](#ok)    [ok?](#ok)    [omit](#omit)    [or](#or)    [ordered?](#ordered)    [pc!](#pc)    [pd!](#pd)    [pencolor](#pencolor)    [pencolor!](#pencolor)    [pendown!](#pendown)    [pendown?](#pendown)    [penup!](#penup)    [penwidth](#penwidth)    [penwidth!](#penwidth)    [pi](#pi)    [pos?](#pos)    [position](#position)    [print!](#print)    [pu!](#pu)    [pw!](#pw)    [rad/deg](#raddeg)    [rad/turn](#radturn)    [random](#random)    [random\_int](#random\_int)    [range](#range)    [report!](#report)    [rest](#rest)    [right!](#right)    [round](#round)    [rt!](#rt)    [second](#second)    [sentence](#sentence)    [set](#set)    [set?](#set)    [setheading!](#setheading)    [show](#show)    [showturtle!](#showturtle)    [sin](#sin)    [slice](#slice)    [some](#some)    [some?](#some)    [split](#split)    [sqrt](#sqrt)    [sqrt/safe](#sqrtsafe)    [square](#square)    [state](#state)    [store!](#store)    [string](#string)    [string?](#string)    [strip](#strip)    [sub](#sub)    [sum\_of_squares](#sum\_of_squares)    [tan](#tan)    [tau](#tau)    [trim](#trim)    [tuple?](#tuple)    [turn/deg](#turndeg)    [turn/rad](#turnrad)    [turtle\_commands](#turtle\_commands)    [turtle\_init](#turtle\_init)    [turtle\_state](#turtle\_state)    [type](#type)    [unbox](#unbox)    [unwrap!](#unwrap)    [unwrap\_or](#unwrap\_or)    [upcase](#upcase)    [update](#update)    [update!](#update)    [values](#values)    [words](#words)    [ws?](#ws)    [zero?](#zero) +[abs](#abs)    [add](#add)    [and](#and)    [angle](#angle)    [any?](#any)    [append](#append)    [assert!](#assert)    [assoc](#assoc)    [assoc?](#assoc)    [at](#at)    [atan/2](#atan2)    [back!](#back)    [background!](#background)    [between?](#between)    [bg!](#bg)    [bk!](#bk)    [bool](#bool)    [bool?](#bool)    [box?](#box)    [butlast](#butlast)    [ceil](#ceil)    [chars](#chars)    [clear!](#clear)    [coll?](#coll)    [colors](#colors)    [concat](#concat)    [contains?](#contains)    [cos](#cos)    [count](#count)    [dec](#dec)    [deg/rad](#degrad)    [deg/turn](#degturn)    [dict](#dict)    [dict?](#dict)    [diff](#diff)    [dissoc](#dissoc)    [dist](#dist)    [div](#div)    [div/0](#div0)    [div/safe](#divsafe)    [doc!](#doc)    [downcase](#downcase)    [each!](#each)    [empty?](#empty)    [eq?](#eq)    [err](#err)    [err?](#err)    [even?](#even)    [false?](#false)    [fd!](#fd)    [filter](#filter)    [first](#first)    [floor](#floor)    [fn?](#fn)    [fold](#fold)    [forward!](#forward)    [get](#get)    [goto!](#goto)    [gt?](#gt)    [gte?](#gte)    [heading](#heading)    [heading/vector](#headingvector)    [hideturtle!](#hideturtle)    [home!](#home)    [inc](#inc)    [inv](#inv)    [inv/0](#inv0)    [inv/safe](#invsafe)    [join](#join)    [keep](#keep)    [keys](#keys)    [keyword?](#keyword)    [last](#last)    [left!](#left)    [list](#list)    [list?](#list)    [loadstate!](#loadstate)    [lt!](#lt)    [lt?](#lt)    [lte?](#lte)    [map](#map)    [max](#max)    [min](#min)    [mod](#mod)    [mod/0](#mod0)    [mod/safe](#modsafe)    [mult](#mult)    [neg](#neg)    [neg?](#neg)    [neq?](#neq)    [nil?](#nil)    [not](#not)    [odd?](#odd)    [ok](#ok)    [ok?](#ok)    [omit](#omit)    [or](#or)    [ordered?](#ordered)    [pc!](#pc)    [pd!](#pd)    [pencolor](#pencolor)    [pencolor!](#pencolor)    [pendown!](#pendown)    [pendown?](#pendown)    [penup!](#penup)    [penwidth](#penwidth)    [penwidth!](#penwidth)    [pi](#pi)    [pos?](#pos)    [position](#position)    [print!](#print)    [pu!](#pu)    [pw!](#pw)    [rad/deg](#raddeg)    [rad/turn](#radturn)    [random](#random)    [random\_int](#random\_int)    [range](#range)    [report!](#report)    [rest](#rest)    [right!](#right)    [round](#round)    [rt!](#rt)    [second](#second)    [sentence](#sentence)    [set](#set)    [set?](#set)    [setheading!](#setheading)    [show](#show)    [showturtle!](#showturtle)    [sin](#sin)    [slice](#slice)    [some](#some)    [some?](#some)    [split](#split)    [sqrt](#sqrt)    [sqrt/safe](#sqrtsafe)    [square](#square)    [state](#state)    [store!](#store)    [string](#string)    [string?](#string)    [strip](#strip)    [sub](#sub)    [sum\_of_squares](#sum\_of_squares)    [tan](#tan)    [tau](#tau)    [to\_number](#to\_number)    [trim](#trim)    [tuple?](#tuple)    [turn/deg](#turndeg)    [turn/rad](#turnrad)    [turtle\_commands](#turtle\_commands)    [turtle\_init](#turtle\_init)    [turtle\_state](#turtle\_state)    [type](#type)    [unbox](#unbox)    [unwrap!](#unwrap)    [unwrap\_or](#unwrap\_or)    [upcase](#upcase)    [update](#update)    [update!](#update)    [values](#values)    [words](#words)    [ws?](#ws)    [zero?](#zero) ## Function documentation ### abs @@ -1225,10 +1225,11 @@ Takes a list of words and turns it into a sentence. --- ### set -Takes an ordered collection--list or tuple--and turns it into a set. +Takes an ordered collection--list or tuple--and turns it into a set. Returns sets unharmed. ``` (xs as :list) (xs as :tuple) +(xs as :set) ``` [Back to top.](#ludus-prelude-documentation) @@ -1420,6 +1421,14 @@ Returns the sine of an angle. Default angle measure is turns. An optional keywor ### tau No documentation available. +--- +### to_number +Takes a string that presumably contains a representation of a number, and tries to give you back the number represented. Returns a result tuple. +``` +(num as :string) +``` +[Back to top.](#ludus-prelude-documentation) + --- ### trim Trims whitespace from a string. Takes an optional argument, `:left` or `:right`, to trim only on the left or right.