Hacker News
new
|
past
|
comments
|
ask
|
show
|
jobs
|
submit
login
Someone
on June 18, 2022
|
parent
|
context
|
favorite
| on:
How not to teach recursion (2021)
A simpler way multiplication is recursive is the way it is defined for natural numbers in mathematics:
a × b = 0 if b = 0 a × b = a + a × (b - 1) if b ≠ 0
nonsapreiche
on June 19, 2022
[–]
a x b = a if b = 1
ethanwillis
on June 19, 2022
|
parent
[–]
What is a + a x 0? :)
Guidelines
|
FAQ
|
Lists
|
API
|
Security
|
Legal
|
Apply to YC
|
Contact
Search: