Free help with homework

Why join Brainly?

  • ask questions about your assignment
  • get answers with explanations
  • find similar questions


public static boolean hasDuplicates(int [][] inArray) { for (int row = 0; row < inArray.length; row++) { int rowCheck = inArray[row][inArray.length]; for (int col = 0; col < inArray[row].length; col++) { } } return false; }

1 5 1
i dont have in text book
ok in boolean what does false mean
is it a char
Java, C programs can be used for checking of duplication in an 2-d array.
In C++, you could std::sort (as a sequence of std::pairs) and then std::unique or std::adjacent_find in a loop or whatever you need.
Or you could add them to a std::set (or even std::unordered_set) of such pairs, tracking where set.insert().second is false. There are plenty of ways to manipulate a sequence like this.

If you check this 14
You've to print the duplicate entries and use C++ containers. For accurate results and check. Thanks
0 0 0
The Brain
  • The Brain
  • Helper
Not sure about the answer?
Learn more with Brainly!
Having trouble with your homework?
Get free help!
  • 80% of questions are answered in under 10 minutes
  • Answers come with explanations, so that you can learn
  • Answer quality is ensured by our experts