fork download
  1. DIMENSION A(3,4),B(4,5),C(3,5)
  2. READ*,((A(I,J),J=1,4),I=1,3)
  3. READ*,((B(I,J),J=1,5),I=1,4)
  4. DO 7 I=1,3
  5. DO 10 J=1,5
  6. C(I,J)=0.0
  7. DO 20 K=1,4
  8. C(I,J)=C(I,J)+A(I,K)*B(K,J)
  9. 20 CONTINUE
  10. 10 CONTINUE
  11. 7 CONTINUE
  12. PRINT 30,((C(I,J),J=1,5),I=1,3)
  13. 30 FORMAT(2X,5F10.2)
  14. STOP
  15. END
Success #stdin #stdout 0s 5284KB
stdin
1 2 3 4
2 3 4 5
3 4 5 6

1 2 3 4 5
2 3 4 5 6
3 4 5 6 7
4 5 6 7 8
stdout
       30.00     40.00     50.00     60.00     70.00
       40.00     54.00     68.00     82.00     96.00
       50.00     68.00     86.00    104.00    122.00