1、关于codeblocks IDE的极速安装
请参考百度经验<<Windows下极速搭建fortran开发环境>>

2、编写代码,
如下:
program main
implicit none
open(168,FILE="c:\\fortran.txt")
close(168)
print *,"已经在C盘根目录下创建了空文件fortran.txt"
end
3、在codeblocks中编译,链接,如下图:

4、运行,结果如下:


时间:2026-02-12 04:04:07
1、关于codeblocks IDE的极速安装
请参考百度经验<<Windows下极速搭建fortran开发环境>>

2、编写代码,
如下:
program main
implicit none
open(168,FILE="c:\\fortran.txt")
close(168)
print *,"已经在C盘根目录下创建了空文件fortran.txt"
end
3、在codeblocks中编译,链接,如下图:

4、运行,结果如下:

