Skip to content

Commit 3df8d22

Browse files
authored
Merge pull request #208 from bilawalmehmood/patch-4
Create positive_and_negtive_count_in_array
2 parents 4b7e784 + f131dfc commit 3df8d22

File tree

1 file changed

+23
-0
lines changed

1 file changed

+23
-0
lines changed
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
#include<iostream>
2+
using namespace std;
3+
int main(){
4+
int a[5]={1,2,4,4,5};
5+
int b[5]={5,4,4,2,1};
6+
int c=0;
7+
for (int i=0; i<5; i++)
8+
{
9+
for (int j=0; j<5; j++)
10+
{
11+
if (a[i]==b[j])
12+
{
13+
c=c+1;
14+
}
15+
}
16+
}
17+
if(c==5)
18+
{
19+
cout<<"0";
20+
}
21+
else
22+
cout<<"not match";
23+
}

0 commit comments

Comments
 (0)