## #: y (Antibase 2)

Returns the binary expansion of a given number y as a Boolean list.

```   #: 21
1 0 1 0 1```

If y contains 4 atoms (integers) then returns 4 numerals, as a matrix of 4 rows

```   #: 21 10 31 7
1 0 1 0 1
0 1 0 1 0
1 1 1 1 1
0 0 1 1 1```

### Common uses

1. Decimal to binary conversion (as above).

2. Detect an odd number

• But see below for a better method

```   isOdd=: 13 : '{: #: y'   NB. return final digit {: of binary expansion #: of y
isOdd 22
0
isOdd 23
1```

## x #: y (Antibase)

Generalizes the action of (#:y) to other bases than 2 (including mixed bases).

```   2 #: 21                  NB. A single atom: 2 shows only the final binary digit
1
2 2 2 2 2 #: 21          NB. 5 atoms in x gives 5 binary digit in result
1 0 1 0 1
2 2 2 2 2 #: 21 10 31 7
1 0 1 0 1
0 1 0 1 0
1 1 1 1 1
0 0 1 1 1```

### Common uses

1. Convert list of decimal digits to number

```   digitsOf=: 13 : '(x#10) #: y'
8 digitsOf 90801
0 0 0 9 0 8 0 1```

2. Convert y in seconds to time-interval in (hours,minutes,seconds)

```   HMS=: 24 60 60 & #:
HMS 86399
23 59 59```

3. Detect an odd number

```   isOdd=: 2 & #:
isOdd 21
1
isOdd 21 10 31 7
1 0 1 1```