Fortran has subroutines and functions. Functions can take multiple arguments and return a single value (however arguments can also be modified). Subroutines can take multiple arguments, which can be inputs, outputs, or both (arguments can be declared inputs or outputs, but it's not required) and don't return a value. And then there's common blocks for sharing variables between subroutines...