user14508963
user14508963

Reputation: 21

What does the format '(a,2(2x,3i4))' mean?

I am working with some code in Fortran where the format of writing out to some file is '(a,2(2x,3i4))'.

How do you break each part of this down to understand what it means?

Upvotes: 0

Views: 346

Answers (1)

Steve Lionel
Steve Lionel

Reputation: 7267

  • a = character string of the length in the value
  • 2( = group repeat of what's in the parentheses two times
  • 2x = skip two columns
  • 3i4 = 4-digit integer, left padded with blanks if needed, repeated three times

Upvotes: 2

Related Questions