Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <cstdio>
- using namespace std;
- const int CHUNKSIZE = 64;
- int*** b_ints;
- int main(int argc, char** argv)
- {
- b_ints = new int**[CHUNKSIZE];
- for(int i = 0; i < CHUNKSIZE; i++)
- {
- b_ints[i] = new int*[CHUNKSIZE];
- for(int j = 0; j < CHUNKSIZE; j++)
- {
- b_ints[i][j] = new int[CHUNKSIZE];
- for (int x = 0; x < CHUNKSIZE; x++)
- {
- for (int y = 0; y < CHUNKSIZE; y++)
- {
- for (int z = 0; z < CHUNKSIZE; z++)
- {
- if(b_ints[x][y][z])
- {
- printf("\nfail\n");
- }
- else
- {
- printf("test %d %d %d \n",x,y,z);
- }
- }
- }
- }
- }
- }
- }
- Output:
- test 0 0 0
- test 0 0 1
- test 0 0 2
- test 0 0 3
- test 0 0 4
- test 0 0 5
- test 0 0 6
- test 0 0 7
- test 0 0 8
- test 0 0 9
- test 0 0 10
- test 0 0 11
- test 0 0 12
- test 0 0 13
- test 0 0 14
- test 0 0 15
- test 0 0 16
- test 0 0 17
- test 0 0 18
- test 0 0 19
- test 0 0 20
- test 0 0 21
- test 0 0 22
- test 0 0 23
- test 0 0 24
- test 0 0 25
- test 0 0 26
- test 0 0 27
- test 0 0 28
- test 0 0 29
- test 0 0 30
- test 0 0 31
- test 0 0 32
- test 0 0 33
- test 0 0 34
- test 0 0 35
- test 0 0 36
- test 0 0 37
- test 0 0 38
- test 0 0 39
- test 0 0 40
- test 0 0 41
- test 0 0 42
- test 0 0 43
- test 0 0 44
- test 0 0 45
- test 0 0 46
- test 0 0 47
- test 0 0 48
- test 0 0 49
- test 0 0 50
- test 0 0 51
- test 0 0 52
- test 0 0 53
- test 0 0 54
- test 0 0 55
- test 0 0 56
- test 0 0 57
- test 0 0 58
- test 0 0 59
- test 0 0 60
- test 0 0 61
- test 0 0 62
- test 0 0 63
- RUN FINISHED; Segmentation fault; core dumped; real time: 20ms; user: 0ms; system: 0ms
- I hereby conclude that my build environment is insane.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement