题解列表

筛选

一元二次方程

摘要:解题思路:还是定义函数好用,这不用管负值,用if分类传-b*b+4ac即可解决gen小于0注意事项:参考代码:#include<iostream> #include<cmath>//用sqrt开方 ……

给用Java的开一下荒土

摘要:解题思路:注意事项:参考代码:import java.util.Scanner; public class Main { public static void main(String[] a……

矩阵对角线求和

摘要:解题思路:注意事项:参考代码:a = list(map(int,input().split()))b = list(map(int,input().split()))c = list(map(int,……

寻找三位数

摘要:解题思路:注意事项:参考代码:for i in range(100,334):    a = 2*i    b = 3*i    if len(set(str(a)+str(b)+str(i))) =……

逆序数——python

摘要:解题思路:注意事项:参考代码:n = int(input())L = list(map(int,input().split()))s = 0while len(L)>1:    a = L[0]   ……

利用列表内置函数解决

摘要:解题思路:利用list函数count注意事项:参考代码:times = int(input())s = []for i in range(times):    s += [j for j in map……

题解 1095: The 3n + 1 problem

摘要:解题思路:注意事项:还得先比较输入的两个数的大小!!!参考代码#include<stdio.h> int main() {     int a,b,m,n,j,temp;     int su……