[問題] 哪裡有問題
program test
real :: x, y
write(*,*) 'input x=?'
read(*,*) x
do while(1.0/(1-x),x/=0)
y=ln(1.0/(1-x))
write(*,*) x, y
write(*,*) 'input x=?'
read(*,*) x
enddo
end
問題出在(1.0/(1-x),x/=0)
error 561-','found where a ')' was expected
想說應該是逗號那個x/=0是多餘的
可是x/=0明明就是條件 為什麼又不行
然而當我把x/=0去掉時
又會出現write(*,*) 'input x=?'這裡有錯誤
怎麼會這樣?
--
※ 發信站: 批踢踢實業坊(ptt.cc)
◆ From: 59.114.243.98
推
03/24 18:50, , 1F
03/24 18:50, 1F
→
03/24 18:55, , 2F
03/24 18:55, 2F
→
03/24 19:12, , 3F
03/24 19:12, 3F
→
03/24 19:12, , 4F
03/24 19:12, 4F
推
03/24 19:20, , 5F
03/24 19:20, 5F
→
03/24 19:22, , 6F
03/24 19:22, 6F
→
03/24 19:23, , 7F
03/24 19:23, 7F
推
03/24 19:34, , 8F
03/24 19:34, 8F
→
03/24 19:35, , 9F
03/24 19:35, 9F
→
03/24 19:51, , 10F
03/24 19:51, 10F
推
03/24 20:01, , 11F
03/24 20:01, 11F
→
03/24 20:04, , 12F
03/24 20:04, 12F
→
03/24 20:05, , 13F
03/24 20:05, 13F
推
03/24 20:11, , 14F
03/24 20:11, 14F
→
03/24 20:12, , 15F
03/24 20:12, 15F
→
03/24 20:12, , 16F
03/24 20:12, 16F
→
03/24 20:29, , 17F
03/24 20:29, 17F
Fortran 近期熱門文章
PTT數位生活區 即時熱門文章