#include <perms.h>
// Edinburgh IMP77 Compiler - Version 8.4
//
// 1 %begin
int main(int argc, char **argv) { /*%begin*/
_imp_initialise(argc, argv);
// 2 %own %integer %array negarray(-1:1) = 42, 1234567, 17
static int NEGARRAY[3] = {42, 1234567, 17};
// 3 %const %short %integer %array index(0:1) = 0, -1
const short int INDEX[2] = {0, -1};
// 4 %integer i
int I;
// 5
// 6 i = 1
I = 1;
// 7
// 8 write(negarray(index(i)), 4); ! Should be negarray(-1) which is 42.
_imp_WRITE(NEGARRAY[INDEX[I] + 1], 4);
// 9 newline
_imp_NEWLINE();
// 10
// 11 %endofprogram
_imp_stop(0);
return 0;
end_0:;
}