Better HN
top
new
best
ask
show
jobs
Log in
Sign up
Better HN
Comment
by
rajasharan
· 15y ago · 0 comments
my first reaction was it's going to be O(9^n) worst case - but there is & after f "$1" which spawns its own process for each number. Not bad - maybe its a good algo if all are single digits
Comments
[–]
srl
15y ago
Of course, the proper algorithm, when all are single digits, is to use an array [10]int.