Created
December 30, 2016 17:29
-
-
Save sohana08/d7cbc930daf3e6cfb8bf9640baabc376 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
using namespace std; | |
int main() | |
{ | |
int n; | |
cin>>n; | |
int m; | |
cin>>m; | |
int arr[n]; | |
int i; | |
for( i=0;i<n;i++) | |
{ | |
cin>>arr[i]; | |
} | |
for(i=0;i<n;i++) | |
{ | |
if(arr[i]==m) | |
{ | |
cout<<i<<endl; | |
} | |
} | |
return 0; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
does anything seems wrong in this code?? because its giving me wrong answer