|
-
December 11th, 2003, 01:38 PM
#4
ok i seem to have gotten a lot closer to my desired output for the anomalies array:
while(!infile.eof())
{
location = search(starNames, target, numStars);
if(location != -1)
if(signal >= hvalues[location] || signal <= lvalues[location])
anomalies[location] = anomalies[location] +1;
else
anomalies[location] = 0;
else
cout<<"Star doesn't exist." <<endl;
getline(infile, target);
infile >> signal;
infile.ignore(256,'\n');
}
doing that gives me the correct number for 3 out of the 5 stars.
its giving one anomaly for two of the stars. im unsure why its doing that.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|