logoalt Hacker News

wvenabletoday at 3:32 AM1 replyview on HN

Correct. But indexing into an array is logic that computes a result when it is called.


Replies

adastra22today at 4:00 AM

There are two opposing philosophical viewpoints here. Some view mathematics as a model for understanding the real world. Some see the real world as instantiation of mathematics.

Is an array a function? From one perspective, the array satisfies the abstract requirements we use to define the word "function." From the other perspective, arrays (contiguous memory) exist and are real things, and functions (programs) exist and are something else.

show 1 reply