, Fortran 90 . , , .
COMMON - . , , 1 . - :
integer a, b
common /globals/ a, b
globals :
module globals
implicit none
integer a, b
end module globals
use a b
program main
use globals
implicit none
a = 4
b = 2
end program main
DATA , , , :
module AREA1
implicit none
integer :: a = 0
integer :: b = 1
integer :: c = 2
end module AREA1
module AREA2
implicit none
real :: i = 10.0
real :: j = -20.0
real :: k = 30.0
real :: l = -40.0
end module AREA2
use AREA1 use AREA2 implicit none , .
:
1 , , . , COMMON, , .
- ( ), . ,
integer a, b
common /globals/ a, b
integer i, j
common /globals/ i, j
. , a b, :
use globals, only: i => a, j => b
( , only, , . - : only: a, i => b, a i.)
, globals , :
integer k(2)
common /globals/ k