If an array is empty, it looks like you can\'t check it\'s length using \".length\". What\'s the best way to check if an array is empty?
Since .Net >= 5.0 the best way is to use Any:
if(!array.Any()) { //now you sure it's empty }
For nullable arrays:
if(!(array?.Any() == true)) { //now you sure it's null or empty }