从1开始到100,不断累加2,得到的就是奇数了。#include<stdio.h>int main(){ int a; for(a=1;a<=100;a+=2) printf("%d\n",a); return 0;}