提交时间:2024-05-05 17:02:44
运行 ID: 145751
#include<bits/stdc++.h> using namespace std; int main(){ int a[101],i; a[1]=3; for(i=2;i<=100;i++){ a[i]=a[i-1]+2; } a[2]=3;a[1]=101; cout<<a[1]<<endl<<a[2]<<endl; for(i=3;i<=100;i++){ a[i]=a[i-1]+2; if(i==100){ cout<<a[i]; } else{ cout<<a[i]<<endl; } } return 0; }