Created
September 12, 2018 17:30
-
-
Save bollu/24763515906ca1b4388ecd7775461d84 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
A[N][M][O] | |
A[x][y][z] = M * O * x + M * y + z | |
let y = O * 2 | |
A[x][O * 2][z] = M * O * x + M * (O * 2) + z = M * O * (x + 2) + M * 0 + z = A[x + 2][2][z] | |
We will infer the array index as {x + 2, 2, z}. | |
If x = [1..N], we will assume that this array index was "incorrect", even | |
though if O * 2 < M, the above array access is correct. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment