Biggest Number (C语言代码) 摘要:解题思路:注意事项:参考代码:#include<stdio.h> #include<string.h> #include<stdlib.h> typedef struct Dode{ …… 题解列表 2018年12月30日 1 点赞 4 评论 1655 浏览 评分:9.9
用筛法求之N内的素数。 (C语言代码) 摘要:解题思路:注意事项:参考代码:#include <stdio.h> #include <stdlib.h> //Eratosthenes筛选法求素数 int main() { …… 题解列表 2018年12月30日 0 点赞 0 评论 616 浏览 评分:0.0
C语言程序设计教程(第三版)课后习题1.6 (C语言代码) 摘要:解题思路:一个接一个比较注意事项:不要弄混比较量参考代码:#include<stdio.h>int main(){ int a,b,c,max; scanf("%d%d%d",&a,&b,&c…… 题解列表 2018年12月30日 0 点赞 0 评论 425 浏览 评分:0.0
荣耀 (C++代码) 摘要:解题思路: 我是把0~9的晶体管数存到number的一维数组中 people数组是记录每组每个人分别的杀怪数量 题解列表 2018年12月30日 6 点赞 0 评论 1076 浏览 评分:9.9
优质题解 algorithm数据结构算法 元素配对 (C/C++语言代码) 摘要:解题思路:本题利用两个数组分别存储两组数据。我使用的是vector动态数组。要使得所有配对元素差的绝对值之和最大。可以将第一个数组中元素升序(或降序),第二个数组中元素降序(或升序)。如题目引例中n=…… 题解列表 2018年12月30日 9 点赞 1 评论 977 浏览 评分:9.9
getchar( )和字符数组求个数 (C语言代码) 摘要:解题思路:#include <type.h>isalpha()是否是字母;isdigit()是否是数字注意事项:参考代码:#include <stdio.h> #include <ctype.h>…… 题解列表 2018年12月30日 1 点赞 0 评论 809 浏览 评分:0.0
A+B for Input-Output Practice (IV) (C语言代码) 摘要:解题思路:注意事项:参考代码:#include<stdio.h>int main(){ int a,b=0,n,count=0; scanf("%d ",&n); while(~sc…… 题解列表 2018年12月30日 0 点赞 0 评论 467 浏览 评分:0.0
元素配对 (C++代码) 摘要:解题思路:思路很明显,要使差的绝对值最大,只需将一个序列的第i大与第二个序列的第i小配对即可。注意事项:本例输入较大,建议不使用输入流。参考代码:#include<cstdio>#include<al…… 题解列表 2018年12月30日 0 点赞 0 评论 688 浏览 评分:0.0
A+B for Input-Output Practice (III) (C语言代码) 摘要:解题思路:注意事项:参考代码:#include<stdio.h>int main(){ int a,b=0,n,count=0; scanf("%d ",&n); while(~sc…… 题解列表 2018年12月30日 0 点赞 0 评论 467 浏览 评分:0.0
A+B for Input-Output Practice (II) (C语言代码) 摘要:解题思路:注意事项:参考代码:#include<stdio.h>int main(){ int a,b=0,n,count=0; scanf("%d ",&n); while(~sc…… 题解列表 2018年12月30日 0 点赞 0 评论 488 浏览 评分:0.0