首页 > 解决方案 > Shell 参数作为 Fortran 的参数

问题描述

我想用下面的shell线轻松计算一个数字的平方

./exe 参数

这是fortran代码

PROGRAM

    REAL*8 :: x,fx

    fx=x**2

    print*,'The square of ',x,' is ',fx

END PROGRAM

我想 x 作为参数,我可以使用哪一行?

标签: functionshellfortranargumentsexecutable

解决方案


推荐阅读