1415:挚爱C语言(动态开辟二维数组空间C/C++解决问题) 摘要:c++语言动态开辟二维数组空间 ```cpp char** p = new char* [n]; for (int i = 0; i < n; i++) { p[i] = n…… 题解列表 2024年10月04日 0 点赞 0 评论 399 浏览 评分:9.9
蓝桥杯2024年第十五届省赛真题-成绩统计 **注意:**本题的方差计算公式疑似有误。应为$$\sigma^2=\frac{\sum(X-\mu)^2}{N}$$。其他的没什么好说的,这题就是模拟。**代码:**```cpp#includeusingnamespacestd;vectora,v;//a为所有数字。 题解列表 2024年10月04日 10 点赞 0 评论 2067 浏览 评分:10.0
3209: 蓝桥杯2024年第十五届省赛真题-好数 摘要:解题思路:注意事项:参考代码:def is_good_number(num): k = 1#初始化变量k为1,用于跟踪当前数字的位数 (这里从右边开始,第一位是奇数) while num:…… 题解列表 2024年10月04日 1 点赞 0 评论 768 浏览 评分:0.0
1644:最长字符串(使用结构体存储,扩展解法) ```cpp#include#include#includeusingnamespacestd;structword{stringw;intsize;};intmain(){wordwords[50];//声明一个包含50个word结构体的数组stringstr;getline(cin, 题解列表 2024年10月04日 0 点赞 0 评论 482 浏览 评分:9.9
[蓝桥杯算法提高VIP-种树] - 我搜搜搜搜搜 #思路搜索:排除等效冗余+特判```cpp#include#defineULLunsignedlonglong#defineLLlonglong#definePIIpairusingnamespacestd;constintN=1*1e6+10, 题解列表 2024年10月04日 2 点赞 0 评论 657 浏览 评分:10.0
蓝桥杯2024年第十五届省赛真题-团建 摘要:解题思路:dfs,也就是深度优先搜索注意事项:有一个测试样例是错的,输入内容如下:4 2 49868141 62921933 1 1 49868141 62921933 1 2 3 1 1 …… 题解列表 2024年10月04日 8 点赞 1 评论 2177 浏览 评分:10.0
1192: 十->二进制转换 ```cpp#include#includeusingnamespacestd;//进制转换并输出函数不考虑特殊情况voidtransport(intx){x=abs(x);vectorv;vector::iteratorit;while(x!=0){it=v.begin();v.insert(it, 题解列表 2024年10月03日 0 点赞 0 评论 587 浏览 评分:9.9
oliv_排除法暴力循环 摘要:解题思路:注意事项:参考代码:#include<stdio.h>int main(){ int sum = 0, arr[4]; for(int i=0; i<4; i++) …… 题解列表 2024年10月03日 0 点赞 0 评论 747 浏览 评分:0.0
编写题解 1050: [编程入门]结构体之成绩记录 摘要:解题思路:注意事项:参考代码:#include<stdio.h>struct Student{char number[10];char name[10];int score[3];};int main…… 题解列表 2024年10月02日 0 点赞 0 评论 594 浏览 评分:0.0
编写题解 1050: [编程入门]结构体之成绩记录(指针) 摘要:#include <stdio.h> // 引入标准输入输出头文件 // 定义学生结构体 struct Student { char number[10]; // 学号 char …… 题解列表 2024年10月02日 0 点赞 0 评论 595 浏览 评分:0.0