Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

String comparison with a percentage in accuracy result

 
Orange Tonik
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello experts,
Is there a certain library that can provide the functionality of comparing two strings and giving a percentage of their matching.

Regards
 
Campbell Ritchie
Sheriff
Posts: 48406
56
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Welcome to the Ranch.

You obviously missed the naming policy on the way in. And Tonik is misspelt.

There probably is, in which case you can find it on Google, but it would be easy to write your own.
 
Orange Tonik
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
There's a naming policy? Plus my real name's Toni Krause so Tonik is my nickname
 
Vilmantas Baranauskas
Ranch Hand
Posts: 89
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Not sure if this is what you are looking for but check StringUtils.getLevenshteinDistance from apache's commons-lang.
 
Amit Ghorpade
Bartender
Posts: 2854
10
Fedora Firefox Browser Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Orange Tonik, welcome to Javaranch,
and yes there is a naming policy you'll find it here.
No matter you use your nickname, but your name should sound real


Hope this helps
 
fred rosenberger
lowercase baba
Bartender
Posts: 12086
29
Chrome Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
when you registered, right above the line where you entered your display name, was the line:
Publicly Displayed Name (This name must conform to our naming policy):
That would seem to imply we have a naming policy.

This policy is strictly enforced. You can always go to this thread to discuss the policy, but i'd advise reading the whole thing first to avoid re-hashing any argument.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic