Modern Fortran is not working in VS Code

No such thing.

PRINT statement is a supported feature in the language.

The standard states, “The PRINT statement specifies some other processor-dependent unit, which is the same as the unit identified by * in a WRITE statement and is the same as the unit identified by the value of the named constant OUTPUT_UNIT of the intrinsic module ISO_FORTRAN_ENV (16.10.2.24).”

Additionally with FORMAT in a case like so

   use, intrinsic :: iso_fortran_env, only : output_unit
   character(len=*), parameter :: fmtg = "(*(g0:,1x))"
   integer, allocatable :: x(:)
   x = [ 1, 2, 3 ]
   print fmtg, x
   write(*,fmtg) x
   write(output_unit,fmtg) x
end

is for all practical purposes equivalent.

C:\temp>gfortran p.f90 -o p.exe

C:\temp>p.exe
1 2 3
1 2 3
1 2 3