# Write a dfn to produce a vector of the first n odd numbers.
Prob1 ⇐ 1+2×↕
# Write a dfn which returns the percent (from 0 to 100) of passing
# (65 or higher) grades in a vector of grades.
Prob2 ⇐ (100×1⌊+´÷≠)65⊸≤
# Write a dfn which returns the number of words [in a] character vector.
Prob3 ⇐ ≠(¬-˜⊢×·+`»⊸>)∘(' '⊸≠)⊔⊢
# Write an APL dfn which returns a 1 if the opening and closing
# parentheses in a character vector are balanced, or a zero otherwise.
Prob4 ⇐ (∧´∘≥⟜0∧0≡·⊑¯1⊸↑)·+`'('⊸=-')'⊸=
# Write an APL dfn which produces an n×n identity matrix.
Prob5 ⇐ ≍˜ ⥊ 1∾⥊⟜0
# BQNcrate suggests the shorter and slightly less magical =⌜˜↕
# This solution is quite a bit asymptotically faster, at least
# according to extremely unscientific testing with •_timed.
# Write a dfn which returns the magnitude of the range (i.e. the
# difference between the lowest and highest values) of a numeric array.
Prob6 ⇐ (⌈´-⌊´)⥊
# Write a dfn which selects the floating point (non-integer) numbers
# from a numeric vector.
Prob7 ⇐ (⌊≠⊢)⊸/
# Write a dfn which produces a multiplication table.
Prob8 ⇐ ×⌜˜1+↕
# Write a dfn which produces n month moving averages for a year’s
# worth of data.
Prob9 ⇐ (+´÷≠)˘↕
# Write a dfn which solves a linear system.
# Prob10 ⇐ +˝∘×⎉1‿∞⁼