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.
非常简单的问题。
说我有
real, dimension(0:100) :: realResults
我想迭代realResults,最终创建表单数组的json
[[x1,y1], [x2,y2], [x3, y3], ... ]
我很确定我想使用“do”,但我不确定如何使用
谢谢
在 Fortran 90 中,您可以进行数组迭代,例如:
do i = lbound(realResults), ubound(realResults) ! do something with realResults(i) end do
FORTRAN 和 json 在同一段中?!?!怎么回事?也许是这样的:
do 10 i = 0, 100 C do something with realResults(i) 10 continue