Actually using foreach for expanding array is useful and clear pattern.