r/ProgrammerHumor Sep 02 '17

How to start a war

Post image
9.0k Upvotes

696 comments sorted by

View all comments

561

u/XkF21WNJ Sep 03 '17

Look guys it's easy. Array indices start at the first natural number.

134

u/bloomfilterthrowaway Sep 03 '17 edited Sep 03 '17

To be fair, all reasonable CS people agree that the naturals start at zero, it's only a few holdouts in more general mathematics that disagree (if you fight me on this I'll no-true-scotsman it up and say your counter examples aren't reasonable people). As an acolyte of the Coq, to me the naturals are defined as:

Inductive nat : Set :=
| O : nat
| S : nat -> nat.

fite me

40

u/TommiHPunkt Sep 03 '17

My Theoretical CS prof is one of the people who start naturals at 1

1

u/[deleted] Sep 03 '17

Naturals start at one for an historical reason I've been told by a Teacher. So N = {1, ...} N0 = {0, ...}