diff --git a/n_occurrence.cpp b/n_occurrence.cpp new file mode 100644 index 0000000..0d99277 --- /dev/null +++ b/n_occurrence.cpp @@ -0,0 +1,25 @@ +#include +using namespace std; +int main() +{ + int n,i,m,count=0; + cout<<"Enter the size of an array : "; + cin>>m; + int arr[m]; + cout<<"Enter the elements of array : "; + for(i=0; i>arr[i]; + } + cout<<"Enter the element to be check : "; + cin>>n; + for(i=0; i