stable
Added duplicates handling and some restyling