about array

susiede (9)
hello everyone can someone help me about array plsss i really need help right now

using one-dimensional array. create a program that will count the number of the same intries in a series number based on the user specific no. to count
EXPECTED output
Enter no.1:2
Enter no.2:1
Enter no.3:1
Enter no4:2
what number to v=count?1
total number 1 is 2

should use a counter
i appretiate those who will answer
kbw (5371)
Duplicate post:
http://www.cplusplus.com/forum/general/87973/
susiede (9)
this is my code
#include<iostream>
using namespace std;
int main()
{
int n,hn,nc;
int i;
int count;
float totaln;
count=0;

cout<<"ENTER MANY NUMBERS TO INPUT?:"<<endl;
cin>>hn;

for(i=1;i<=hn;i++)
{

cout<<"ENTER NUMBER :"<<i<<":";
cin>>n;}



cout<<"WHAT NUMBER TO COUNT:"<<endl;
cin>>nc ;
count=0;
totaln+=n;

cout<<"THE TOTAL NUMBER IS:"<<totaln;


system("PAUSE");
}
Registered users can post here. Sign in or register to post.