program Console45
implicit none
integer,parameter::n=3
character(10)::string
real::a(n,n)
integer::i,er
open(11,file='1.txt')
do
read(11,*) string
if(er/=0) exit
if(string(1:7)=='downtri') then
do i=1,n
read(11,*) a(i,:)
end do
end if
end do
do i=1,n
write(*,*) a(i,:)
end do
pause
end program Console45
欢迎光临 Fortran Coder (http://bbs.fcode.cn/) | Powered by Discuz! X3.2 |