摘要:
#include<stdio.h> #include<stdlib.h> //题目:2/1,3/2,5/3,8/5,13/8,21/13...求出这个数列的前20项之和 int main(){ int i,n; float a,b,s,t; while(1){ printf("请输入相加项数:"); scanf("%d",&n); s=0; a=2; b=1; for(i=1;i<=n;i++){ 阅读全文
posted @ 2019-08-26 08:54
狗狗王
阅读(2278)
评论(0)
推荐(0)
摘要:
1 #include 2 #include 3 //题目:打印菱形 4 5 int main(){ 6 int a,b,x,y; 7 x=8; 8 y=8; 9 for(a=1;a<=13;a++){ 10 for(b=1;b<=15;b++) 11 if(b==x||b==y) 12 printf("*"); 13 ... 阅读全文
posted @ 2019-08-26 05:41
狗狗王
阅读(385)
评论(0)
推荐(0)

浙公网安备 33010602011771号