筛选N以内的素数 摘要:解题思路: 通过双层for循环,外层循环i不断与内层循环j匹配,根据 i % j == 0 && i != j 判断他不是素数。注意事项:参考代码:import java.util.Scanner; …… 题解列表 2023年11月19日 0 点赞 0 评论 572 浏览 评分:0.0
三种方法解排序(C语言) 摘要:解题思路:注意事项:参考代码:方法1:使用冒泡排序#include // 冒泡排序函数 void bubbleSort(int arr[], int n) { int temp; …… 题解列表 2023年11月19日 0 点赞 0 评论 646 浏览 评分:9.9
函数+递归求解 摘要:解题思路:注意事项:参考代码:#include<bits/stdc++.h>using namespace std;int sum=0;int f(int x){ int t=x;//(保存一下x的值…… 题解列表 2023年11月19日 0 点赞 0 评论 572 浏览 评分:9.9
很简单的水仙花,使我大脑旋转。 摘要:解题思路:直接按照水仙花定义求解注意事项:关键在于如何表示百位,十位,个位的数值,三位数除100再取10的余得百位,除10取10的余得十位,直接取10的余得个位。参考代码:#include <stdi…… 题解列表 2023年11月19日 0 点赞 0 评论 506 浏览 评分:9.9
最高的分数 解题思路:输入格式直接转换成数组利用sum(list)求出数组的最大值注意事项:参考代码:n=int(input())a=list(map(int,input().split()))m=max(a)print(m) 题解列表 2023年11月19日 0 点赞 0 评论 483 浏览 评分:0.0
2824: 求出e的值 摘要:``` #include using namespace std; double e=1,n,jie=1,num; int main(){ cin>>n; for( int i=1;i…… 题解列表 2023年11月19日 0 点赞 0 评论 446 浏览 评分:0.0
坤坤也能看懂 摘要:解题思路:注意事项:参考代码:#include<stdio.h>int main(){ int a,b,c; scanf("%d%d%d",&a,&b,&c); if(a*a+b*b==c*c||b*…… 题解列表 2023年11月19日 0 点赞 0 评论 608 浏览 评分:9.9
题解 1022: [编程入门]筛选N以内的素数 摘要: #include using namespace std; int main(){ int a,b,sh,i; cin>>a; for(…… 题解列表 2023年11月19日 0 点赞 0 评论 398 浏览 评分:0.0
2518: 信息学奥赛一本通T1620-质因数分解 摘要:``` #include using namespace std; int main(){ int r,sum=0; cin>>r; int a = r; …… 题解列表 2023年11月19日 1 点赞 0 评论 496 浏览 评分:9.9
2752: 整型数据类型存储空间大小 摘要:解题思路:注意事项:先int后short参考代码:#include <iostream>using namespace std;int main(){ cout <<sizeof(int)<<"…… 题解列表 2023年11月19日 0 点赞 0 评论 553 浏览 评分:9.9