题解列表

筛选

1190: 剔除相关数

摘要:核心:就挺难说的,暴力求解吧代码:def func(l):     c = []     l1 = [0] * len(l)     res = []     for i in range(l……

题解(C语言)

摘要:```c #include #include #include typedef struct { int data; // 存储符合条件的数字 int sig……

1156题解(C语言)

摘要:```c #include #include // 计算数字每位的立方和,并判断该和是否等于原数字 int fun(int i) { int n = i, sum = 0; ……

链表合并(先排序,后合并)不用排序算法

摘要:这个题好像有两种思路: 1.先合并,后排序 2.先排序,后合并 看了大家的解法都是第一种思路,我想试一下第二种思路。因为两个链表从键盘输入的时候是学号是无序的,所以我想能不能创建链表的时候就按学……

1198: 取石子游戏

摘要:核心:    威佐夫博弈 a == (int)((b - a) * ((sqrt(5) + 1) / 2)):先手输,其他则先手赢代码:from math import sqrt while T……

1197: 发工资咯(贪心算法)

摘要:核心:票票从大开始扣,数量是最少的代码:while True:     l = [int(x) for x in input().split()]     n = l[0]     if n =……

1159题解(C语言)

摘要:```c #include #define MAX 101 void fun(int n, int m) { int a[MAX]; // 存储生成的数字的数组 int ……

各位大佬看看我的

摘要:解题思路:注意事项:参考代码:#include <stdio.h>void SumAge(char a[4]) {    for (size_t i = 0; i <4; i++) {        ……

简单的a+b (C语言代码)

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