Skip to content
sneppets

sneppets

  • Privacy
find the duplicates

2 Ways to Find the Duplicates in Array in O(n) time

December 6, 2018December 8, 2018 Editorial StaffLeave a Comment on 2 Ways to Find the Duplicates in Array in O(n) time

Given an input array of integers, your goal is to find the duplicates present in the array in an effective way using Java Collections HashSet and HashMap. Note, you need to achieve this in O(n) time i.e., you should be able to… Read More!

Algo, Java arrays, HashMap, HashSet, space complexity, time complexity

Posts navigation

Newer posts
Copyright © 2018 Sneppets. All Rights Reserved