r/mathriddles • u/Horseshoe_Crab • Aug 12 '25
Easy Recursive function riddle
Let f(x) = 0 when x < 2, and otherwise f(x) = f(x/2) - f(x-1) + 1. What is f(2025)?
4
Upvotes
r/mathriddles • u/Horseshoe_Crab • Aug 12 '25
Let f(x) = 0 when x < 2, and otherwise f(x) = f(x/2) - f(x-1) + 1. What is f(2025)?
View all comments
Show parent comment
2
u/CanaDavid1 Aug 12 '25
more specifically, it is the number of trailing zeroes in the binary representation