1、关于codeblocks IDE的极速安港粕登漪装请参考百度经验<<Windows下极速搭建fortran开发环境>>
2、【创建fortran工程】
3、【编写代码】program mai艘绒庳焰n implicit none integer::a,i,flag flag=1 r髫潋啜缅ead *,a do i=2,a-1 if(mod(a,i)==0)then flag=0 exit end if end do if(flag==1)then print *,a,"是素数" else print *,a,"不是素数" end ifend
4、【在codeblocks中编译、链接】
5、【运行、测试结果】