摘要: #include<iostream> #include<stdio.h> #include<string.h> #include<algorithm> #include<math.h> using namespace std; int a[6]={100,50,10,5,2,1}; int num( 阅读全文
posted @ 2018-10-02 19:53 星海violet 阅读(108) 评论(0) 推荐(0) 编辑
摘要: 总是记不住sort排序特点……一道水题记一下 题目链接: http://acm.hdu.edu.cn/showproblem.php?pid=2020 输入n(n<=100)个整数,按照绝对值从大到小排序后输出。题目保证对于每一个测试实例,所有的数的绝对值都不相等。 Input 输入数据有多组,每组 阅读全文
posted @ 2018-10-02 19:24 星海violet 阅读(155) 评论(0) 推荐(0) 编辑
摘要: 题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=2018 Problem Description 有一头母牛,它每年年初生一头小母牛。每头小母牛从第四个年头开始,每年年初也生一头小母牛。请编程实现在第n年的时候,共有多少头母牛? Input 输入数据由多 阅读全文
posted @ 2018-10-02 18:30 星海violet 阅读(144) 评论(0) 推荐(0) 编辑