首页 > 其他 > 详细

抓交通事故肇事犯

时间:2015-03-24 23:01:47      阅读:279      评论:0      收藏:0      [点我收藏+]

问题:

        一辆卡车撞人逃跑,一个人说前两位相同,一个人说后两位相同,一个数学家说是一个数的平方,这个四位数的车牌号是多少。

    

#include <stdio.h>
#include <stdlib.h>
#include<math.h>
/* run this program using the console pauser or add your own getch, system("pause") or input loop */

int main(int argc, char *argv[]) {
	int a, b;
	for(a=1; a<=9; a++)
		for(b=0; b<=9; b++)
		{
			int i;
			for(i=31; i<100; i++)
			if(sqrt(1100*a+11*b) == i)
			printf("%d\n", 1100*a+11*b);
		}
	return 0;
}
//7744



抓交通事故肇事犯

原文:http://blog.csdn.net/orangeisnotapple/article/details/44600343

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!