The array is inside the class.
So it would be just
ob1.display();
And declare your member function as taking no parameters.
Salem
Posting Sage
11,531 posts since Dec 2005
Reputation Points: 5,862
Solved Threads: 953
Well that's up to the code in the display function.
Perhaps
display ( int whichArray );
For example
if it's zero, display arr
if it's one, display arr1
Salem
Posting Sage
11,531 posts since Dec 2005
Reputation Points: 5,862
Solved Threads: 953
So why do you have an array in your class, if all you do is pass in an array to work on?
Are you sure that arr and arr1 are not just two instances of your class?
Salem
Posting Sage
11,531 posts since Dec 2005
Reputation Points: 5,862
Solved Threads: 953