24小时热门版块排行榜    

CyRhmU.jpeg
查看: 1815  |  回复: 3
当前只显示满足指定条件的回帖,点击这里查看本话题的所有回帖

memgr

铜虫 (正式写手)


[交流] 【求助】fortran出错了

本人刚开始学fortran  想请教大家一下下面的程序哪个地方错了 老是提示
E:\Text1.f90(10): error FOR3351:inconsistent usage of KBC detected between A and )
E:\Text1.f90(14): error FOR3351: inconsistent usage of KBC detected between A and )
E:\Text1.f90(18): error FOR2290: implicit type for YC detected between YC and -
E:\Text1.f90(18): error FOR2290: implicit type for XC detected between XC and -
E:\Text1.f90(22): warning FOR4265: symbol XC referenced but not set
E:\Text1.f90(22): warning FOR4265: symbol KAC referenced but not set
E:\Text1.f90(22): warning FOR4265: symbol YC referenced but not set
E:\Text1.f90(22): warning FOR4270: unused symbol LBE
程序是如下
implicit none
real :: x1, y1, x2, y2, x3, y3, a, b, kab, kbc, xe
print *, " input the parameters "
read(*, *)x1, y1, x2, y2, x3, y3, a, b
kab = (y2-y1)/(x2-x1)
kbc = (y3-y2)/(x3-x2)
kab = (y3-y1)/(x2-x1)
xe = (y2-b+kab*a-kbc*x2)/(kab-kbc)
write (*, *) xe
end
谢谢各位
回复此楼

» 猜你喜欢

» 本主题相关价值贴推荐,对您同样有帮助:

» 抢金币啦!回帖就可以得到:

查看全部散金贴

已阅   回复此楼   关注TA 给TA发消息 送TA红花 TA的回帖
memgr(金币+5): 2011-03-31 10:56:23
引用回帖:
Originally posted by memgr at 2011-03-30 18:52:45:
奥 写错了 这行应该是kac  谢谢啊 ,但是改了之后还是不行呢 为什么呢

把 kac 加到第二行中就没有问题了……
4楼2011-03-30 19:21:48
已阅   回复此楼   关注TA 给TA发消息 送TA红花 TA的回帖
相关版块跳转 我要订阅楼主 memgr 的主题更新
普通表情 高级回复(可上传附件)
信息提示
请填处理意见