题解列表

筛选

2805: 乘方计算 快速幂方法

摘要:解题思路: 快速幂注意事项:参考代码:#include <iostream> // #include <sstream> #include <cstdio> // #include <algor……

计负均正1061题解

摘要:解题思路:注意事项:参考代码:#include<iostream>using namespace std;int main(){    int num[20];    double count=0.0……

图的遍历-DFS

摘要:```cpp #include using namespace std; #define ll long long int n;//节点数 const int N = 55;//最大节点数 ……

动态规划Java解题

摘要:解题思路:动态规划的简单应用注意事项:最好得拿张纸写写,再用断点去一点点领悟其运行过程参考代码:/*   关于动态规划的一道题目   一个美食家在一条街上从前往后吃,每一次吃的都要比上次的更加好   ……

记录一下TOM数这道题的题解

摘要:用字符串的话这道题还蛮简单的,就是第一次2的32次方的位数判断错了,没跑出来参考代码:#include<stdio.h>int Sum(char* ps){    int sum=0;    whil……

非常基础的方式

摘要:解题思路:注意事项:参考代码:#include <stdio.h>int main(){ int i,j; int arr[100] = { 0 }; for (i = 0; i < 100; i+……

奇怪的鸡兔同笼问题

摘要:解题思路:注意事项:参考代码:import java.util.Scanner;/** * c1986鸡兔同笼 * Date:2023/2/10 * Author:Cherish */public c……