|
|
1.1 ! root 1: struct t { struct s { character(6) a(2),b;integer c} a(3); integer b(6) } ! 2: procedure sam(x) ! 3: t x(4),y ! 4: integer z(5,7) ! 5: x(2).a(2).a(2) = "abc" ! 6: y.b(3) = 4 ! 7: z(2,4)->s.c = 2 ! 8: z->s.a(2) = "xyz" ! 9: end ! 10: procedure ! 11: struct { field(3) a,b,c,d; field(10000) e; field(3) f} x ! 12: integer m ! 13: x.a = 2 ! 14: x.b = 2 ! 15: x.c = 2 ! 16: x.d = 2 ! 17: x.e = 2 ! 18: x.f = 2 ! 19: x.a-=2 ! 20: x.b-=2 ! 21: x.c-=2 ! 22: x.d-=2 ! 23: x.a*=2 ! 24: x.b*=2 ! 25: x.c*=2 ! 26: x.d*=2 ! 27: x.c+=2 ! 28: x.c *= x.d += x.b = (x.a=1)+2 ! 29: end ! 30: ! 31: ! 32: procedure ! 33: struct t { field(0:3) a; field(20) b; field(60) c} ! 34: t x ! 35: integer k ! 36: k = x.a+x.b+x.c ! 37: end ! 38: procedure ! 39: struct t { field(50) a,b,c,d,e } ! 40: integer i ! 41: t x(5) ! 42: x(2).a = i ! 43: x(2).b = i ! 44: x(2).c = i ! 45: x(2).d = i ! 46: x(2).e = i ! 47: ! 48: do i = x(1).a, x(3).b,x(5).e ! 49: x(i**2).b *= x(i**2+1).e ! 50: end ! 51: procedure ! 52: struct t {real a} x ! 53: x.a = 1. ! 54: { ! 55: struct t {integer b, c} y ! 56: y.b=1 ! 57: } ! 58: x.a = 2. ! 59: end ! 60: common(cc) complex a ! 61: integer b ! 62: ! 63: procedure ! 64: integer a ! 65: {logical a;a = .true.} ! 66: a = 1 ! 67: {logical a;a=.false.} ! 68: a=2 ! 69: end ! 70: procedure ! 71: a = 1 ! 72: end ! 73: procedure a(b) ! 74: end ! 75: ! 76: procedure alltyp(y) ! 77: struct { ! 78: real a(3) ! 79: long real b(3) ! 80: integer c(3) ! 81: complex d(3) ! 82: logical e(3) ! 83: character(8) f(3) ! 84: character(9) g(3) ! 85: } x, y ! 86: ! 87: x.a(3) = x.b(3) = x.c(3) = x.d(3) = 1 ! 88: x.e(3) = false ! 89: x.f(3) = x.g(3) = "abcdefg" ! 90: end ! 91: procedure ! 92: integer i,j ! 93: logical l ! 94: switch(i) ! 95: { ! 96: case 1: if(l) goto case 2 ! 97: else switch(j) ! 98: { ! 99: case 1: goto case 2 ! 100: case 2: goto case 1 ! 101: } ! 102: case 3: j=2 ! 103: case 2: while(i!=j) ++j ! 104: } ! 105: end
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.