Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
Fortran 问题:format('CRDET',2i5,1p3e12.4) 或 format('CRDET',2i5,1p,3e12.4) 哪个是正确的格式语句?不同之处在于最后两个参数之间的逗号分隔符。
走出去,阅读标准但不测试它..似乎两种形式都是相同的,P适用于所有3个E
1) 它 (P) 适用于所有随后解释的 F、E、D 和 G 编辑描述符,直到遇到另一个比例因子,
2) 用于分隔列表 flist 中的列表项的逗号可以省略如下: ** 在 P 编辑描述符和紧随其后的 F、E、D 或 G 编辑描述符之间
我认为逗号形式更安全,因为它不清楚重复的编辑描述符是否属于第 2 点。