题解列表

筛选

2890:细菌的繁殖与扩散 题解

摘要:解题思路:整比较暴力,不过固定9阶方阵,时间不长定义两个元素相同菌群矩阵,遍历第一个矩阵将结果记录到新的矩阵中注意事项:每天更新矩阵时用深拷贝copy.deepcopy(),保证两矩阵地址更不同,互不……

编写题解 2813: 药房管理

摘要:解题思路:注意事项:参考代码:m=int(input())n=int(input())list1=list(map(int,input().split()))#记录每个病人希望取走的药品数量z=0#没……

题目 1009: [编程入门]数字的处理与判断

摘要:解题思路:1. 通过循环去掉最后一位,同时让计数加    2.通过循环将数字的每一位放入数组,再遍历输出。注意事项:参考代码:#include<stdio.h>//建立数组int w[10];int ……

超级简便的python

摘要:解题思路:利用map()和sum()注意事项:参考代码:s=list(map(int,input().split()))print(sum(s))……

C语言-公约公倍

摘要:解题思路:最小公倍数易求,最大公约数难求,要用递归,为避免用递归的麻烦,直接先求最小公倍数,再通过最小公倍数与最大公约数之积=输入的两数乘积得出最大公约数注意事项:参考代码:#include<stdi……

题目 2774: 计算三角形面积

摘要:解题思路:注意事项:参考代码:#include<iostream> #include<math.h> using namespace std; int main() { double x1……

已知三点求面积

摘要:解题思路:注意事项:参考代码:#include <stdio.h>#include <math.h>int main(){ float x1, y1, x2, y2, x3, y3; scanf("%……

题目 2750: 字符菱形

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

编写题解 2810: 鸡尾酒疗法

摘要:解题思路:注意事项:参考代码:n=int(input())jl,jx=map(int,input().split())j=jx/jllist1=[]for i in range(n-1):    gl……

多边形内角和

摘要:解题思路:注意事项:参考代码:#includeusing namespace std;int main(){ int n; cin>>n; int a[n-1]; int sum1=(n-2)*180……