题解列表

筛选

编写题解 2805: 乘方计算

摘要:解题思路:注意事项:参考代码:#include <bits/stdc++.h>using namespace std;int main(){    int a,n,sum=1;cin>>a>>n;  ……

一行代码解决

摘要:print(len([i for i in list(map(int, input().split())) if i & (i - 1) == 0]) if input() else 0)……

我AC的第一个难题

摘要:参考代码:#include<bits/stdc++.h>//100以内数的加减 using namespace std; bool jiancha(string s) {     string……

生日蛋糕问题用c++来实现

摘要:解题思路: 1:我们将蛋糕的每一层看作是一个圆柱体,并且用半径R和高度H来描述。2:通过给定的蛋糕体己N和层数M,我们需要找到一种制作方案,来使得蛋糕的外表面积最小。注意事项:1:在编写代码时,要注意……

3岁都能看懂

摘要:解题思路:注意事项:参考代码:#include <stdio.h>int main() {    int k;    scanf("%d", &k);        if (k == 1 || k =……

回文字符串四种情况

摘要:解题思路:1.字符串s本身回文aaa2.全为"lqb"字符,补充另一半即可lqb ==> bql_lqb3.前部分回文ioilqb ==> bql_ioilqb4.部分回文bioi_blq ==>ql……