Logo

Programming-Idioms

This language bar is your friend. Select your favorite languages!
  • Fortran

Idiom #153 Concatenate string with integer

Create the string t as the concatenation of the string s and the integer i.

write (unit=t,fmt='(A,I0)') s, i

This assumes that there is enough space in t.
t : String := s & Integer'Image (i);

New implementation...
< >
programming-idioms.org