Skip to content

NestWhile

Applies a function repeatedly while a predicate holds.

$ wo 'NestWhile[#/2 &, 8, EvenQ]'
1