#include "stdafx.h" #include <iostream> using namespace std; int main() { int a[100]={0}; cout<<sizeof(a)/sizeof(a[0])<<endl; return 0; } 运行结果: 转载于:https://www.cnblogs.com/audi-car/p/4403715.html