In table t below, fill in the "kilos" values by dividing each of the 4 animals' pounds column value by 2.2.

name sex age fixed pounds kilos

"Toggle"

"female"

3

true

48

"Fritz"

"male"

4

true

92

"Nori"

"female"

6

true

35.3

"Sasha"

"female"

1

false

6.5

Then consider the table and the 2 duntction definitions.

fun is-female(r): r["sex"] == "female"  end
fun kilograms(r): r["pounds"] / 2.2     end
fun is-heavy(r):  r["kilos"] > 25       end

Match each table description on the left, to the Circle of Evaluation that will produce it.

Produces a table containing Toggle, Nori and Sasha, with an extra column showing their weight in kilograms

1

A

(filter (sort t "pounds" false) is-female)

Produces a table containing Sasha, Nori and Toggle (in that order)

2

B

(build-column (filter t is-female) "kilos" kilograms)

Produces a table with an extra column for kilos, but only animals with more than 25 kilos

3

C

(filter (build-column t "kilos" kilograms) is-heavy)

Won’t run: will produce an error (if so, why?)

4

D

(build-column (filter t is-heavy) "kilos" kilograms)

Produces a table containing Sasha, Toggle, and Nori (in that order)

5

E

(filter (build-column (build-column t "female" is-female) "kilos" kilograms) is-heavy)

Produces an empty table - with no animals at all!

6

F

(build-column (sort (filter t is-female) "age" true) "kilos" kilograms)

These materials were developed partly through support of the National Science Foundation, (awards 1042210, 1535276, 1648684, 1738598, 2031479, and 1501927). CCbadge Bootstrap by the Bootstrap Community is licensed under a Creative Commons 4.0 Unported License. This license does not grant permission to run training or professional development. Offering training or professional development with materials substantially derived from Bootstrap must be approved in writing by a Bootstrap Director. Permissions beyond the scope of this license, such as to run training, may be available by contacting contact@BootstrapWorld.org.