0

Is Array of size 0 illegal by definition or it depends on language?

skaffman
  • 390,936
  • 96
  • 800
  • 764

1 Answers1

1

It is not illegal by definition, yet it does depend on the language. Java is fine with it, depending on the compiler used in C you might have trouble with it but in general it works there too.

Somewhat related discussion on C++ and zero length arrays: Array of zero length

Community
  • 1
  • 1
jzd
  • 23,279
  • 8
  • 53
  • 76