#include<stdio.h>
main()
{
int i,m[8];
do
{
m[i]=2*i+2;
i++;
}
while (i<8&&i<=7);
printf("\n%d \n%d",m[4.3],m[4.7]);
}
错误提示:C:\tc\3\3.cpp(11) : error C2108: subscript is not of integral type
C:\tc\3\3.cpp(11) : error C2108: subscript is not of integral type
C:\tc\3\3.cpp(12) : warning C4508: 'main' : function should return a value; 'void' return type assumed
执行 cl.exe 时出错.
3.exe - 1 error(s), 0 warning(s)