题解列表

筛选

C语言训练-自由落体问题

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

粗俗易懂,新手都能会

摘要:解题思路:注意事项:参考代码:#include<stdio.h>int main(){ int a[10],x; for(int i=0;i<=8;i++) scanf("%d\n",&a[i]); ……

粗俗易懂,新手都能会

摘要:解题思路:注意事项:参考代码:#include<stdio.h>int main(){ int a[10],t; for(int i=0;i<=9;i++) scanf("%d",&a[i]); fo……

C语言:用指针解

摘要:解题思路:因为字符串无法直接赋值,所以利用指针切换地址即可参考代码:#include <stdio.h>#include <string.h>int main() {    char str1[100……

通过数组标记

摘要:解题思路:用数组给每个人标号,将每次循环报3的人赋值0,直到只剩1个找到它的标号。参考代码:#include <stdio.h>// 函数pan用于找出最后剩下的一个元素int pan(int *a,……