Writing on the same line in FORTRAN -
in fortran, each time 1 uses write new line produced. in order control working of program being executed, write on screen current value of variable, on same line (erasing previous value , starting @ beginning of line). is, like
1 continue "update value of a" write(*,*) backspace "screen" goto 1 something write(*,*,advance='no') (incorrect anyway) not quite need: write values of a 1 after on long line.
a trick shown want follows
do l=1,lmax ...update a... write(*,'(1a1,<type>,$)') char(13), enddo where <type> format specifier a (i.e., i0 integer).
the key char(13), carriage return, , $ in format descriptor. don't know if there name $, know works displaying on screen--for output file a on each line.
Comments
Post a Comment