-: y (Halve)

Divides the value of y by 2.

The following is an animation for the Halve monadic verb that might be useful to those new to J

Embedded application/x-shockwave-flash

Common uses

Has advantages in tacit definitions over (expression) % 2.

See Also


x -: y (Match)

Returns Boolean value 1 iff x is equivalent to y.

   'no' -: |. 'on'
1
   'no' -: 'yes'
0

Common uses

Matching strings of varying length.

   reply=: 'yes'

   reply = 'yes'
1 1 1
   reply = 'no'
|length error
|   reply    ='no'
   reply -: 'yes'
1
   reply -: 'no'
0

See Also


CategoryVocTemplate CategoryVoc CategoryWorkInProgress

Vocabulary/minusco (last edited 2011-12-21 01:21:30 by IanClark)