求文档: 计算:100×99-99×98-98×97-97×96-96×95-95×94+„+4×3-3×2-2×1. 15
2个回答
展开全部
原式=(100×99-99×98)+(98×97-97×96)+(96×95-95×94)+…+(4×3-3×2)+2×1=99*2+97*2+...+3*2+1*2=2*(99+97+...+3+1)=5000;
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
展开全部
#include <stdio.h>
main()
{
int x;
int y;
int i;
int s=100*99;
for (i=1;i<99;i++)
{
x=100-i;
y=x-1;
s=s-x*y;
printf("x=%d,y=%d,i=%d,s=%d\n",x,y,i,s);
printf("test\n");
}
printf("%d\n",s);
}
解析过程为
x=99,y=98,i=1,s=198
test
x=98,y=97,i=2,s=-9308
test
x=97,y=96,i=3,s=-18620
test
x=96,y=95,i=4,s=-27740
test
x=95,y=94,i=5,s=-36670
test
x=94,y=93,i=6,s=-45412
test
x=93,y=92,i=7,s=-53968
test
x=92,y=91,i=8,s=-62340
test
x=91,y=90,i=9,s=-70530
test
x=90,y=89,i=10,s=-78540
test
x=89,y=88,i=11,s=-86372
test
x=88,y=87,i=12,s=-94028
test
x=87,y=86,i=13,s=-101510
test
x=86,y=85,i=14,s=-108820
test
x=85,y=84,i=15,s=-115960
test
x=84,y=83,i=16,s=-122932
test
x=83,y=82,i=17,s=-129738
test
x=82,y=81,i=18,s=-136380
test
x=81,y=80,i=19,s=-142860
test
x=80,y=79,i=20,s=-149180
test
x=79,y=78,i=21,s=-155342
test
x=78,y=77,i=22,s=-161348
test
x=77,y=76,i=23,s=-167200
test
x=76,y=75,i=24,s=-172900
test
x=75,y=74,i=25,s=-178450
test
x=74,y=73,i=26,s=-183852
test
x=73,y=72,i=27,s=-189108
test
x=72,y=71,i=28,s=-194220
test
x=71,y=70,i=29,s=-199190
test
x=70,y=69,i=30,s=-204020
test
x=69,y=68,i=31,s=-208712
test
x=68,y=67,i=32,s=-213268
test
x=67,y=66,i=33,s=-217690
test
x=66,y=65,i=34,s=-221980
test
x=65,y=64,i=35,s=-226140
test
x=64,y=63,i=36,s=-230172
test
x=63,y=62,i=37,s=-234078
test
x=62,y=61,i=38,s=-237860
test
x=61,y=60,i=39,s=-241520
test
x=60,y=59,i=40,s=-245060
test
x=59,y=58,i=41,s=-248482
test
x=58,y=57,i=42,s=-251788
test
x=57,y=56,i=43,s=-254980
test
x=56,y=55,i=44,s=-258060
test
x=55,y=54,i=45,s=-261030
test
x=54,y=53,i=46,s=-263892
test
x=53,y=52,i=47,s=-266648
test
x=52,y=51,i=48,s=-269300
test
x=51,y=50,i=49,s=-271850
test
x=50,y=49,i=50,s=-274300
test
x=49,y=48,i=51,s=-276652
test
x=48,y=47,i=52,s=-278908
test
x=47,y=46,i=53,s=-281070
test
x=46,y=45,i=54,s=-283140
test
x=45,y=44,i=55,s=-285120
test
x=44,y=43,i=56,s=-287012
test
x=43,y=42,i=57,s=-288818
test
x=42,y=41,i=58,s=-290540
test
x=41,y=40,i=59,s=-292180
test
x=40,y=39,i=60,s=-293740
test
x=39,y=38,i=61,s=-295222
test
x=38,y=37,i=62,s=-296628
test
x=37,y=36,i=63,s=-297960
test
x=36,y=35,i=64,s=-299220
test
x=35,y=34,i=65,s=-300410
test
x=34,y=33,i=66,s=-301532
test
x=33,y=32,i=67,s=-302588
test
x=32,y=31,i=68,s=-303580
test
x=31,y=30,i=69,s=-304510
test
x=30,y=29,i=70,s=-305380
test
x=29,y=28,i=71,s=-306192
test
x=28,y=27,i=72,s=-306948
test
x=27,y=26,i=73,s=-307650
test
x=26,y=25,i=74,s=-308300
test
x=25,y=24,i=75,s=-308900
test
x=24,y=23,i=76,s=-309452
test
x=23,y=22,i=77,s=-309958
test
x=22,y=21,i=78,s=-310420
test
x=21,y=20,i=79,s=-310840
test
x=20,y=19,i=80,s=-311220
test
x=19,y=18,i=81,s=-311562
test
x=18,y=17,i=82,s=-311868
test
x=17,y=16,i=83,s=-312140
test
x=16,y=15,i=84,s=-312380
test
x=15,y=14,i=85,s=-312590
test
x=14,y=13,i=86,s=-312772
test
x=13,y=12,i=87,s=-312928
test
x=12,y=11,i=88,s=-313060
test
x=11,y=10,i=89,s=-313170
test
x=10,y=9,i=90,s=-313260
test
x=9,y=8,i=91,s=-313332
test
x=8,y=7,i=92,s=-313388
test
x=7,y=6,i=93,s=-313430
test
x=6,y=5,i=94,s=-313460
test
x=5,y=4,i=95,s=-313480
test
x=4,y=3,i=96,s=-313492
test
x=3,y=2,i=97,s=-313498
test
x=2,y=1,i=98,s=-313500
test
-313500
所以最后答案是-313500
main()
{
int x;
int y;
int i;
int s=100*99;
for (i=1;i<99;i++)
{
x=100-i;
y=x-1;
s=s-x*y;
printf("x=%d,y=%d,i=%d,s=%d\n",x,y,i,s);
printf("test\n");
}
printf("%d\n",s);
}
解析过程为
x=99,y=98,i=1,s=198
test
x=98,y=97,i=2,s=-9308
test
x=97,y=96,i=3,s=-18620
test
x=96,y=95,i=4,s=-27740
test
x=95,y=94,i=5,s=-36670
test
x=94,y=93,i=6,s=-45412
test
x=93,y=92,i=7,s=-53968
test
x=92,y=91,i=8,s=-62340
test
x=91,y=90,i=9,s=-70530
test
x=90,y=89,i=10,s=-78540
test
x=89,y=88,i=11,s=-86372
test
x=88,y=87,i=12,s=-94028
test
x=87,y=86,i=13,s=-101510
test
x=86,y=85,i=14,s=-108820
test
x=85,y=84,i=15,s=-115960
test
x=84,y=83,i=16,s=-122932
test
x=83,y=82,i=17,s=-129738
test
x=82,y=81,i=18,s=-136380
test
x=81,y=80,i=19,s=-142860
test
x=80,y=79,i=20,s=-149180
test
x=79,y=78,i=21,s=-155342
test
x=78,y=77,i=22,s=-161348
test
x=77,y=76,i=23,s=-167200
test
x=76,y=75,i=24,s=-172900
test
x=75,y=74,i=25,s=-178450
test
x=74,y=73,i=26,s=-183852
test
x=73,y=72,i=27,s=-189108
test
x=72,y=71,i=28,s=-194220
test
x=71,y=70,i=29,s=-199190
test
x=70,y=69,i=30,s=-204020
test
x=69,y=68,i=31,s=-208712
test
x=68,y=67,i=32,s=-213268
test
x=67,y=66,i=33,s=-217690
test
x=66,y=65,i=34,s=-221980
test
x=65,y=64,i=35,s=-226140
test
x=64,y=63,i=36,s=-230172
test
x=63,y=62,i=37,s=-234078
test
x=62,y=61,i=38,s=-237860
test
x=61,y=60,i=39,s=-241520
test
x=60,y=59,i=40,s=-245060
test
x=59,y=58,i=41,s=-248482
test
x=58,y=57,i=42,s=-251788
test
x=57,y=56,i=43,s=-254980
test
x=56,y=55,i=44,s=-258060
test
x=55,y=54,i=45,s=-261030
test
x=54,y=53,i=46,s=-263892
test
x=53,y=52,i=47,s=-266648
test
x=52,y=51,i=48,s=-269300
test
x=51,y=50,i=49,s=-271850
test
x=50,y=49,i=50,s=-274300
test
x=49,y=48,i=51,s=-276652
test
x=48,y=47,i=52,s=-278908
test
x=47,y=46,i=53,s=-281070
test
x=46,y=45,i=54,s=-283140
test
x=45,y=44,i=55,s=-285120
test
x=44,y=43,i=56,s=-287012
test
x=43,y=42,i=57,s=-288818
test
x=42,y=41,i=58,s=-290540
test
x=41,y=40,i=59,s=-292180
test
x=40,y=39,i=60,s=-293740
test
x=39,y=38,i=61,s=-295222
test
x=38,y=37,i=62,s=-296628
test
x=37,y=36,i=63,s=-297960
test
x=36,y=35,i=64,s=-299220
test
x=35,y=34,i=65,s=-300410
test
x=34,y=33,i=66,s=-301532
test
x=33,y=32,i=67,s=-302588
test
x=32,y=31,i=68,s=-303580
test
x=31,y=30,i=69,s=-304510
test
x=30,y=29,i=70,s=-305380
test
x=29,y=28,i=71,s=-306192
test
x=28,y=27,i=72,s=-306948
test
x=27,y=26,i=73,s=-307650
test
x=26,y=25,i=74,s=-308300
test
x=25,y=24,i=75,s=-308900
test
x=24,y=23,i=76,s=-309452
test
x=23,y=22,i=77,s=-309958
test
x=22,y=21,i=78,s=-310420
test
x=21,y=20,i=79,s=-310840
test
x=20,y=19,i=80,s=-311220
test
x=19,y=18,i=81,s=-311562
test
x=18,y=17,i=82,s=-311868
test
x=17,y=16,i=83,s=-312140
test
x=16,y=15,i=84,s=-312380
test
x=15,y=14,i=85,s=-312590
test
x=14,y=13,i=86,s=-312772
test
x=13,y=12,i=87,s=-312928
test
x=12,y=11,i=88,s=-313060
test
x=11,y=10,i=89,s=-313170
test
x=10,y=9,i=90,s=-313260
test
x=9,y=8,i=91,s=-313332
test
x=8,y=7,i=92,s=-313388
test
x=7,y=6,i=93,s=-313430
test
x=6,y=5,i=94,s=-313460
test
x=5,y=4,i=95,s=-313480
test
x=4,y=3,i=96,s=-313492
test
x=3,y=2,i=97,s=-313498
test
x=2,y=1,i=98,s=-313500
test
-313500
所以最后答案是-313500
更多追问追答
追问
............不要计算机程序计算,,用实际点的方法
追答
那你就提项吧,100x99-99x98=99x(100-98)=99x2,后面的同理为97x2,95x2……然后把2提出来,那就是(99-97-95-……-1)x2,然后就是答案了
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询