题解列表

筛选

一种减小复杂度的质因数分解法

摘要:解题思路:本题中主要思路就是遍历题目给出区间,分解其中每一个元素的质因式主要的部分为:1.判断质数的函数 2.生成升序质数序列(一般只需要从小到大判断元素并且加入列表就行了,不需要再专门排序)3.从题……

模拟计算器

摘要:解题思路:注意事项:参考代码:#include <iostream>using namespace std;int main(){    int a,b;    char c;    cin>>a>>……

编写题解 2790: 分段函数

摘要:解题思路:注意事项:参考代码#include <iostream>using namespace std;int main(){    float x,y;    cin>>x;    if(x>=0……

编写题解 2792: 三角形判断

摘要:解题思路:注意事项:参考代码:#include <iostream>using namespace std;int main(){    int a,b,c;    cin >>a>>b>>c;   ……

编写题解 2791: 计算邮资

摘要:解题思路:注意事项:参考代码:#include<iostream>using namespace std;int main(){    int c = 0;    int a;    cin>>a; ……

java--study||O.o

摘要:参考代码:import java.util.Scanner; public class Main  { public static void main(String[] args)     ……

[编程入门]密码破译

摘要:#include<bits/stdc++.h> using namespace std; #define IOS ios::sync_with_stdio(false) int main() ……

gets和scanf的区别

摘要:- 注意事项1: scanf()输入字符串时,scanf()遇到空格、回车、Tab结束,但在缓冲区中还留着这些结束符,此后如果使用gets()想去获取下一行字符串,它碰到的却是前面遗留下来的回车(或……

编写题解 2794: 求平均年龄

摘要:解题思路:注意事项:参考代码:#include<iostream>using namespace std;int main(){   int n;    cin >> n;    int sum = ……