boolean


~

boolean

number | number

boolean

Approximate. Similar to round (number) = round (number) – returns true if the rounded inputs are equal. Similar to approximate

show 5.4 ~ 4.7
TRUE


afterp

boolean

word1 | word2

boolean

afterp outputs true if word1 comes after word2. To make the comparison, Logo uses the ASCII codes of the characters in the words. Note that all uppercase letters come before all lowercase letters. See beforep

show afterp "bread "apple
TRUE


approximatep

boolean

number | number

boolean

Returns true if the rounded value of the first number is the same as the rounded value of the second number. Similar to ~. See round

show approximatep 5.4 4.8
TRUE


arrowp

boolean

none

boolean

Returns true if the directional arrow is enabled. See showarrow, hidearrow

show arrowp


attenuatep

boolean

none

boolean

Returns true if the calling turtle is currently attenuating its sound.

show attenuatep


audiowaitp

boolean

none

boolean

Returns true if autowait is set on. See audiowait

show audiowaitp


beforep

boolean

word1 | word2

boolean

beforep outputs true if word1 comes before word2. To make the comparison, Logo uses the ASCII codes of the characters in the words. Note that all uppercase letters come before all lowercase letters. See afterp

show beforep "bread "apple
FALSE


blocksp

boolean

none

boolean

Returns true if blocks mode is enabled.

show blocksp


buttonp

boolean

button (number)

boolean

Returns true if the specified button is pressed. 0 is the left mouse button or joypad button 0, 1 is the right mouse button or joypad button 1

show buttonp 0


camcontrolp

boolean

none

boolean

Returns true if camcontrol is enabled.

show camcontrolp


caseinsensitivep

boolean

none

boolean

Returns true if nocaseinsensitive is enabled.

show caseinsensitivep


collisionp

boolean

turtle (word) | distance (number)

boolean

Returns true if the specified turtle is within the specified distance of the calling turtle. See distance

show collisionp snappy 200
TRUE


consonantp

boolean

word

boolean

Returns true if the first letter of the supplied word is a consonant. Y is considered a vowel. See vowelp

show consonantp "x
TRUE


containsp

boolean

word number or list | list

boolean

Returns true if the specified word or number exists as an item in the specified list. See contains

show containsp "frog [pig duck frog]
true
show containsp 1 [1 2 3 4 5]


databasep

boolean

databasename (word)

boolean

Returns true if the given databasename is a defined database. See newdatabase

show databasep "mydb


debugp

boolean

none

boolean

Returns true if debug is enabled.

show debugp


definedp

boolean

procedurename (word)

boolean

Returns TRUE if the provided procedurename is the name of a defined procedure.

show definedp "myprocedure
TRUE


dictionaryp

boolean

dictionary (word)

boolean

Returns true if the specified dictionary is currently defined. See dictionary, newdictionary

show dictionaryp "mydict


divisorp divp

boolean

numerator (number) | denominator (number)

boolean

returns true of the numerator divides evenly into the denominator. See remainder,

show divisorp 5 20
true


dotp

boolean

[x y (z)] (list)

none

Returns true if there is a dot at the specified co-ordinates. Dots are turtle-specific, and so dotp will only detect the calling turtle’s dots.

show dotp [10 20 30]


dragselectp

boolean

none

boolean

Returns true if dragselect is enabled


dribblep

boolean

none

boolean

Returns true if turtleSpaces is currently dribbling. See dribble


eofp

boolean

none

boolean

Returns true if the current reader is at the end of the file. See reader, writer

show eofp


equalp

boolean

expression | expression

boolean

Returns true if both supplied expressions are equal

show equalp 5 5
TRUE

show equalp 3 5
FALSE


escapep

boolean

none

boolean

Returns true if escape is enabled

show escape


evenp

boolean

number

boolean

Returns true if the provided number is even (0, 2, 4, 6…)

show evenp 6


false

boolean

none

zero

Returns zero (false).

show false


fencep

boolean

none

boolean

Returns true if the calling turtle is in fence mode. See fence

show fencep


filep

boolean

word

boolean

Returns true if the file specified by the given word exists.

show filep "myfile


fluidp

boolean

none

boolean

Returns true if fluid is enabled in the calling turtle

show fluidp


followp

boolean

none

boolean

Returns true if the calling turtle is following another turtle

show followp


gamebuttonp

boolean

buttom

boolean

Returns true if the specified gamepad button is currently pressed.

show gamebuttonp


gradientp

boolean

none

boolean

Returns true if gradient is enabled

show gradientp


greaterequalp

boolean

expression | expression

boolean

Returns true if the first expression is greater than or equal to the second expression.

show greaterequalp 5 3
TRUE

show greaterequalp 3 3
TRUE


greaterp

boolean

expression | expression

boolean

Returns true if the first expression is greater than the second expression.

show greaterp 5 3
TRUE

show greaterp 3 5
FALSE


hatchlingp

boolean

turtlename (word)

boolean

Returns true if the given turtlename is a hatchling.

show hatchlingp "seymour
FALSE


imagep

boolean

imagename (word)

boolean

Returns true if the specified imagename is defined.

show imagep "image


insidep

boolean

[x y z] [[x1 y1 z1] [x2 y2 z2]]

boolean

Returns true if the first set of three-dimensional co-ordinates is within the cube created between the second and third sets of coordinates.

show insidep [0 0 0] [[-10 -10 -10] [10 10 10]]
true


keyclickp

boolean

none

boolean

Returns true if keyclick is enabled. See keyclick

show keyclickp


keyp

boolean

none

boolean

Returns true if there are currently any keys in the keyboard buffer. Often seen with readchar, which will wait for a keypress if there are no keys in the buffer, to mitigate that behaviour. See readchar

show keyp


lessequalp

boolean

expression | expression

boolean

Returns true if the first expression is less than or equal to the second expression.

show lessequalp 3 5
TRUE

show lessequalp 3 3
TRUE


lessp

boolean

expression | expression

boolean

Returns true if the first expression is less than the second expression.

show lessp 3 5
TRUE

show lessp 5 3
FALSE


listp

boolean

item

boolean

Returns true if the provided item is a list.

show listp [frog pig]
TRUE


longwordp

boolean

word, longword or list

boolean

Returns true if the provided input is a long word (a word that contains spaces).

show longwordp |I am a duck|


marcop

boolean

none

boolean

Returns true if the calling turtle has any current marcos attributed to it. If a turtle is expecting a marco, it can simply wait until marcop is true. See marco

show marcop


memberp

boolean

word or list

word or list

Returns true if the result of calling member using similar parameters is not empty.

show memberp "duck [pig duck frog]
true


mimicp

boolean

none

boolean

Returns true if the calling turtle is mimicking another turtle. See mimic

show mimicp


musicp

boolean

musicname (word)

boolean

Returns true if the specified music name is loaded in memory.

show musicp "mymusic


namep

boolean

container (word)

boolean

Returns true if the specified container exists.

show namep "container


nearp

boolean

distance

boolean

Returns true if there are any (nostealth) turtles in the given distance from the calling turtle.

show nearp 200
TRUE


not

boolean

boolean

boolean

Reverses an input boolean, an expression that resolves to either true or false

print not 5 = 4
TRUE


notesp

boolean

none

boolean

Returns true if the playnotes primitive is currently playing.

show notesp


numberp

boolean

word

boolean

Returns true if the supplied input is a number.

show numberp 15
TRUE

show numberp "dog
FALSE


oddp

boolean

number

boolean

Returns true if the provided number is odd (1, 3, 5, 7…)

show oddp 6


osdp

boolean

none

boolean

Returns true if the OSD is currently on. See osd

show osdp


overlayp

boolean

name (word)

boolean

Returns true if the specified overlay exists. See newoverlay

show overlayp "overlay


paperp

boolean

none

boolean

Returns true if paper mode is enabled. See paper

show paperp


playmusicp

boolean

none

boolean

Returns true if music is currently playing.

show playmusicp


procp

boolean

name (word)

boolean

Returns true if the calling turtle has a procedure with the provided name.

show procp "procedure


renderp

boolean

none

boolean

Returns true if rendering is enabled. See render.


searchp

boolean

searchmask (word) | list

boolean

Returns true if the specified search would return a result. See search

show searchp "pig [pig frog duck]
TRUE


sharep

boolean

“sharename

boolean

Returns true if the specified “sharename exists.

show sharep "sharename


shownp

boolean

none

boolean

Returns true if the turtle is not hidden, false if it is.

show shownp
TRUE


soundp

boolean

soundname (word)

boolean

Returns true if the specified sound is loaded in memory.

show soundp "mysound


spacep

boolean

word

boolean

Returns true if the specified space is defined.

show spacep "home
true


specklep

boolean

none

boolean

Returns true if speckle is enabled. See speckle

show specklep


stealthp

boolean

none

boolean

Returns true if the calling turtle is in stealth. See stealth, nostealth

show stealthp


stickerp

boolean

none

boolean

Returns true if the specified sticker is defined. See newsticker

show stickerp


stlbackingp

boolean

none

boolean

Returns true if stlbacking is enabled, otherwise false. See stlbacking, nostlbacking

show stlbackingp


suspendp

boolean

workerid

boolean

Returns true if the specified worker is suspended. See suspend, resume

show suspendp 12


syncp

boolean

none

boolean

Returns true if the calling turtle’s ‘family’ currently has an active sync. See sync

if syncp [sync]


tablep

boolean

name (word)

boolean

Returns true if the named table is defined.

show tablep "mytable


tagp

boolean

tagname (word)

boolean

Returns true if the provided tag name is presently defined. See tag

show tagp "tag


tagshownp

boolean

tagname (word)

boolean

Returns true if the tag with the provided tagname is currently visible (shown). See tag

show tagshownp "tag


tandemp

boolean

none

boolean

Returns true if the calling turtle is tandeming another turtle. See tandem

show tandemp


targetp

boolean

none

boolean

Returns true if the calling turtle is targeting another turtle. See target

show targetp


tetherp

boolean

none

boolean

Returns true if the calling turtle is tethering. See tether

show tetherp


trackp

boolean

none

boolean

Returns true if the calling turtle’s track is being generated / recorded. See track, notrack.

show trackp


trackrenderp

boolean

none

boolean

Returns true if the calling turtle’s track is being rendered.

show trackrenderp


transcriptp

boolean

none

boolean

Returns true if transcript is enabled. See transcript, notranscript


true

boolean

none

true

Returns true. See false

show true


userp

boolean

name (word)

boolean

Returns true if the provided name is a currently defined user.

show userp "Bonnie
true


viewturtlep

boolean

name (word)

boolean

Returns true if the named turtle is currently the view turtle.

show viewturtlep "snappy
true


visiblep

boolean

none

boolean

Returns true if the calling turtle is in view of the current view turtle

show visiblep


vowelp

boolean

character

boolean

Returns true if the provided character is a vowel (a e i o u or y)

show vowelp "u


windowp

boolean

none

boolean

Returns true if the turtle is currently in ‘window’ mode. See window

show windowp


withinp

boolean

number or list | number or list | number of list

boolean

Compares two lists or numbers, returns true if they are within the variance specified by the third list of container. All three lists need to have the same number of parameters. Used mainly for comparing position / proximity of turtles.

show withinp [10 10 10] [15 15 15] [10 10 10]
true

show withinp 5 8 2
false


wrapp

boolean

none

boolean

Returns true if the turtle is currently in ‘wrap’ mode. See wrap, window, fence

show wrapp


wordp

boolean

none

boolean

Returns true if the input is a word.

show wordp "word