C语言训练-阶乘和数* 笨方法 摘要:解题思路:先将符合条件的数字找出来,放在一个数组里,再来排序。希望对大家要帮助参考代码:#include<stdio.h>int R1(int n){ int sum2 = 1; for (; n >…… 题解列表 2023年02月07日 0 点赞 0 评论 417 浏览 评分:8.0
绝对值排序(解决超出限制) 摘要:解题思路:注意事项:参考代码:#include<stdio.h>#include<math.h>int main(){/*输入数据有多组*/ int n; while (scanf("%d", &n)…… 题解列表 2023年02月07日 0 点赞 0 评论 271 浏览 评分:0.0
2806: 人口增长问题 摘要:解题思路:注意事项:参考代码:x,n = map(int,input().split())for i in range(0,n): x += x * 0.001 print('{:…… 题解列表 2023年02月07日 0 点赞 0 评论 441 浏览 评分:0.0
2807:****(标题有敏感词) 摘要:解题思路:注意事项:参考代码:r,m,y = map(int,input().split())r = r * 0.01for i in range(0,y): m += m * rprint(i…… 题解列表 2023年02月07日 0 点赞 1 评论 509 浏览 评分:4.0
python身份证排序解法 摘要:n=int(input().strip())X=[input().strip() for _ in range(n)] #用split函数的话 会放在列表里面,这样排不了序 strip函数拆分字符串返…… 题解列表 2023年02月07日 0 点赞 0 评论 374 浏览 评分:0.0
两个for 循环搞定 摘要:解题思路:用string.h函数,变量len 来进行字符串长度的统计,确定for 语句中的范围利用变量i和变量进行循环嵌套,外循环来进行判断每个数是否在数组中有与之相同 的数如有相同数则用sum来进行…… 题解列表 2023年02月07日 0 点赞 1 评论 855 浏览 评分:8.7
问就是只会枚举 摘要:#include #define endl '\n' using namespace std; typedef long long i64; typedef int i32; typedef…… 题解列表 2023年02月07日 0 点赞 0 评论 438 浏览 评分:0.0
第一次题解 摘要:解题思路:注意事项:参考代码:#include<stdio.h>int main(){ int a[10]={0}; int i,j,x; for(i=0;i<9;i++){ scanf("%…… 题解列表 2023年02月07日 0 点赞 0 评论 283 浏览 评分:0.0
题解 1013: [编程入门]Sn的公式求和 摘要:参考代码:n = int(input()) i = 1sn = 0while i <= n : sn += int(str(2)*i) i += 1print(sn)…… 题解列表 2023年02月07日 0 点赞 0 评论 316 浏览 评分:0.0
题解 1014: [编程入门]阶乘求和 摘要:解题思路:注意事项:参考代码import math #导入模块def main(n): #定义函数 return math.factorial(n)n = int(input())sn = …… 题解列表 2023年02月07日 0 点赞 0 评论 277 浏览 评分:0.0