[Wed Jul 20 11:47:35 JST 2011]
[am@aofd30 processor=x86_64]
[~/12.Work11/21.Climatology/35.Test_Flux/src]
program test_array! Description:!! Author: am!! Host: aofd30! Directory: /work2/am/12.Work11/21.Climatology/35.Test_Flux/src!! Revision history:! This file is created by /usr/local/mybin/nff.sh at 11:44 on 07-20-2011.! use! implicit none! write(*,'(a)')'Program test_array starts.'! write(*,*)'' integer,parameter :: im=3,jm=2 real a1(im,jm),a2(im,jm) k=0 do i=1,im do j=1,jm k=k+1 a1(i,j)=float(k) enddo !j enddo !i a2(:,:)=a1(:,:)*2 print '(A)','a1' do i=1,im print '(10f7.0)',(a1(i,j),j=1,jm) enddo !i print * print '(A)','a2' do i=1,im print '(10f7.0)',(a2(i,j),j=1,jm) enddo !i! write(*,'(a)')'Done program test_array.'! write(*,*)end program test_array$ ifort -o test_array test_array.f90
$ ./test_array
a1
1. 2.
3. 4.
5. 6.
a2
2. 4.
6. 8.
10. 12.