蓝桥杯算法提高VIP-寻找三位数 (C语言描述,dfs) 摘要:解题思路: 很明显这道题需要生成1-9的全排列,从中判断符合条件的结果,使用深度搜索算法就可以解决了。注意事项: 输出的三个 题解列表 2019年01月10日 0 点赞 0 评论 1446 浏览 评分:9.9
DNA (C语言代码) 摘要:参考代码:#include <stdio.h> #include <math.h> #include <stdlib.h> void deal(int a,int b) { in…… 题解列表 2019年01月10日 0 点赞 0 评论 583 浏览 评分:0.0
C语言考试练习题_排列 (智障编程) 摘要:#include <stdio.h> int main() { int a[4],i; for(i=0;i<4;i++) scanf("%d",a+i); pri…… 题解列表 2019年01月10日 0 点赞 2 评论 1107 浏览 评分:7.6
保留字母 ,双下标法 摘要:参考代码:#include<stdio.h> int main() { char str[81]; gets(str); int i=0,k=0; whil…… 题解列表 2019年01月10日 0 点赞 0 评论 474 浏览 评分:0.0
真·哥德巴赫曾猜测 (C++代码)暴力才是王道!!! 摘要:解题思路: 暴力法证明。 纯粹来玩玩而已,不要认真参考代码:首先在写一个代码取出32767的内所有的素数,存到一个数组里面,可以借助文件操作。#include<iostream> #in…… 题解列表 2019年01月10日 0 点赞 2 评论 1004 浏览 评分:9.9
2^k进制数 (C语言代码) 摘要:解题思路:和第1104题“Jam计数法”题相似,这里的while循环则采用flag标志判断循环是否结束参考代码:#include <stdio.h> #include <stdlib.h> #in…… 题解列表 2019年01月10日 0 点赞 0 评论 914 浏览 评分:0.0
去括号 (C++代码)C11,cout..R用法,笑死我了要 摘要:解题思路: 直接这样输出如何?参考代码:#include<bits/stdc++.h> using namespace std; int main(){ cout<<R"(1+1 1…… 题解列表 2019年01月10日 1 点赞 0 评论 9669 浏览 评分:5.4
蓝桥杯2013年第四届真题-错误票据 (C++代码) 摘要:解题思路: 首先用数组存储ID,然后利用排序,然后找出重复的,然后找出断的ID。参考代码:#include <iostream> #include <algorithm> using…… 题解列表 2019年01月10日 0 点赞 1 评论 287 浏览 评分:0.0
统计字符数 (C语言代码) 摘要:解题思路:注意事项:参考代码:#include<stdio.h>#include<string.h>int main(){ char a[99],b,j,g; int sum=0,i,n,l,k=-1…… 题解列表 2019年01月10日 0 点赞 0 评论 563 浏览 评分:0.0
Hanoi塔问题 (C语言代码) 摘要:汉诺塔移动次数问题:有n个盘子的塔借助另一个塔移动到第三个塔的次数为2^n-1;因为递推关系式为move(n)=2move(n-1)+1; move(0)=0故此题代码为#include <stdio…… 题解列表 2019年01月10日 1 点赞 2 评论 2234 浏览 评分:9.9