同行列对角线的格子(C++代码解析与题解) 摘要:代码解析:在 main 函数中,我们首先输入三个整数 N、i 和 j,分别表示方格的大小和给定位置的行号和列号。然后,使用循环输出与给定位置同行的格子位置。遍历从 1 到 N 的每一列,输出格子位置 …… 题解列表 2023年07月19日 0 点赞 0 评论 842 浏览 评分:9.5
计算矩阵边缘元素之和(C++代码) 摘要:参考代码:#include <iostream>using namespace std;int main() { int m, n; cin >> m >> n; int matri…… 题解列表 2023年07月19日 0 点赞 0 评论 750 浏览 评分:8.4
C语言解全排列 摘要:解题思路:注意事项:两种代码,第二种交换的代码由于最终打印顺序不同通过不了此题参考代码:#include <stdio.h>#include <string.h>#include <stdbool.h…… 题解列表 2023年07月19日 0 点赞 0 评论 1013 浏览 评分:9.9
1062: 二级C语言-公约公倍 摘要:解题思路:注意事项:参考代码:#include<stdio.h>int main() { int a[8] = { 0,0,0,1,0,0,0,0 }; scanf_s("%d%d", &a[0], …… 题解列表 2023年07月19日 0 点赞 0 评论 284 浏览 评分:0.0
编写题解 1003: [编程入门]密码破译,扩展使用字符函数解决问题 摘要:解题思路:注意事项:参考代码:#include<stdio.h>int main(){ float M,N,sum = 0.0; scanf("%f %f",&M,&N); for(…… 题解列表 2023年07月19日 0 点赞 0 评论 329 浏览 评分:0.0
1022: [编程入门]筛选N以内的素数(C语言) 摘要: #include #include int sushu(int number) { if(number…… 题解列表 2023年07月18日 0 点赞 0 评论 370 浏览 评分:0.0
1019: [编程入门]自由下落的距离计算 摘要:解题思路:注意事项:参考代码:#include<stdio.h>int main() { float a[3] = { 0,0,0},m,n; scanf_s("%f%f", &m,&n); for …… 题解列表 2023年07月18日 0 点赞 0 评论 273 浏览 评分:0.0
1018: [编程入门]有规律的数列求和 摘要:解题思路:注意事项:参考代码:#include<stdio.h>int main() { float a[8] = { 0,0,2,1,1,1,0,0 }; scanf_s("%f", &a[0]);…… 题解列表 2023年07月18日 0 点赞 0 评论 260 浏览 评分:0.0
石头剪刀布 摘要:解题思路:注意事项:参考代码:#include <bits/stdc++.h>using namespace std;int main(){ //比赛n轮,输入n ,小A的周期长度na,小B的周…… 题解列表 2023年07月18日 0 点赞 0 评论 360 浏览 评分:0.0
石头剪刀布 摘要:解题思路:注意事项:参考代码:#include <bits/stdc++.h>using namespace std;int main(){ //比赛n轮,输入n ,小A的周期长度na,小B的周…… 题解列表 2023年07月18日 0 点赞 0 评论 342 浏览 评分:0.0