Skip to main content
edited tags
Link
Jeff Schaller
  • 68.9k
  • 35
  • 122
  • 268
Source Link
illiterate
  • 1k
  • 9
  • 26

Is 'array=X' always assigned to first element in bash?

Is 'array=X' always assigned to first element in bash? If that is not,maybe I need some "for example" to understand following text from man bash page:

When assigning to indexed arrays, if the optional brackets and subscript are supplied, that index is assigned to; otherwise the index of the element assigned is the last index assigned to by the statement plus one.

please.