07.02.2015, 23:30
It would be 5, as the first size-indicator after the name of the array is set to 5.
"sizeof(BusinessInfo)" will return 5, but your loop won't reach 5 as the loop-condition says: "id < sizeof(BusinessInfo)".
Inside the loop, you'll get values for "id" from 1 to 4.
After the loop, your variable is gone as it's only created inside the loop ("new id = 1").
"sizeof(BusinessInfo)" will return 5, but your loop won't reach 5 as the loop-condition says: "id < sizeof(BusinessInfo)".
Inside the loop, you'll get values for "id" from 1 to 4.
After the loop, your variable is gone as it's only created inside the loop ("new id = 1").

