题解 2901: 查找特定的值

来看看其他人写的题解吧!要先自己动手做才会有提高哦! 
返回题目 | 我来写题解

筛选

查找特定的值(C语言)

摘要:解题思路:注意事项:参考代码:#include<stdio.h>int main(){    int n, x, i, z;     int a[10000];     n = x = z = 0; ……

2901: 查找特定的值

摘要:注意事项:第一遍没做出来!!没有想到bool变量 和 第二个if!!参考代码:#include<iostream>  using namespace std; int main() { bo……

c语言简单解法

摘要:解题思路:利用数组求解,利用break用来使循环终止从而达到前面的i先输出,提前设输出变量=-1,若符合则变量=i+1,避免if多次判断注意事项:不要把赋值和等于号混淆,数组下标从0开始参考代码:#i……

查找特定的值(c语言代码)

摘要:解题思路:注意事项:参考代码:#include <stdio.h> #include <string.h> int main() {     int n = 0, i = 0, x = 0……

编写题解 2901: 查找特定的值

摘要:解题思路:输入-判断-输出注意事项:第一次出现字符参考代码:#include<stdio.h>int main(){    int n,x,i;    scanf("%d\n",&n);    int……

查找特定的值(C语言)

摘要:解题思路:    循环查找数组里的值,一旦找到立马跳出循环注意事项:    注意输出-1参考代码:#include<stdio.h> int main() { int a,n; scanf……

C语言 指针解决问题 练手

摘要:解题思路:注意事项:参考代码:#include<stdio.h>int main  ( ){     int n=0 ,x=0 ,record=1 ;     int a[10500]={0} ;  ……