编写题解 2797: 最高的分数 摘要: #include int main() { int n,a[100],k=0; scanf("%d", &n); for (int q …… 题解列表 2024年11月17日 1 点赞 0 评论 166 浏览 评分:10.0
题目有点抽象 摘要:解题思路:注意事项:参考代码:#include<stdio.h>int main(){ int i,a=0,b=0,c=0,d=0,e=0,f=0; for(i=1;i<=100;i++)…… 题解列表 2024年11月17日 0 点赞 0 评论 231 浏览 评分:10.0
质因数分解 不用引用math函数,极简 摘要:解题思路:大体思路相同,都是用平方根计算注意事项:参考代码:#include<stdio.h>int main(){ int n,max; scanf("%d",&n); for(i…… 题解列表 2024年11月18日 0 点赞 0 评论 246 浏览 评分:10.0
数字三角形 摘要:解题思路:使用动态规划来解决这个问题。从三角形的底部开始,逐层向上计算每个位置到最底层的最大路径和。 对于第i行的第j个元素,它到最底层的最大路径和是它本身加上下一行(第i + 1行)中第j个元素和第…… 题解列表 2024年11月19日 2 点赞 0 评论 345 浏览 评分:10.0
3030: 全排列 摘要:解题思路:注意事项:参考代码:#include"bits/stdc++.h" using namespace std; // 全局变量声明 int l; // 字符串长度 string s; …… 题解列表 2024年11月20日 1 点赞 0 评论 367 浏览 评分:10.0
超容易理解的 摘要:解题思路:注意事项:参考代码:#include<iostream>using namespace std;void verse(int a){ int ret[100]; int count=0; w…… 题解列表 2024年11月20日 2 点赞 0 评论 583 浏览 评分:10.0
3033: 放苹果 摘要:解题思路:注意事项:参考代码:#include"bits/stdc++.h" using namespace std; // 全局变量声明,用于存储测试用例数量和两个整数m和n int t, n…… 题解列表 2024年11月20日 1 点赞 0 评论 329 浏览 评分:10.0
简易链表求和 摘要:解题思路:注意事项:函数名是拼音,英语不好参考代码:#include <stdio.h>#include <stdlib.h>typedef struct node{ int s; int…… 题解列表 2024年11月21日 3 点赞 1 评论 342 浏览 评分:10.0
简短且简单 摘要:解题思路:1. 首先包含了 <stdio.h> 和 <string.h> 头文件,用于输入输出和字符串操作。2. 在 main 函数中,定义了一个字符数组 str 来存储输入的字符串,以及一个整数 f…… 题解列表 2024年11月21日 2 点赞 0 评论 576 浏览 评分:10.0
良心出品,放心食用 摘要:解题思路:这段代码定义了一个数组 A ,并通过循环计算出 N 在一定范围内(小于 55)时对应的某种数量值 A[N - 1] ,然后根据输入的 N 值输出相应的结果。在代码中,首先初始…… 题解列表 2024年11月21日 1 点赞 0 评论 178 浏览 评分:10.0