Skip to content

Instantly share code, notes, and snippets.

@hilda8519
Last active August 29, 2015 14:02
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save hilda8519/69fcc6db1db7efb8e107 to your computer and use it in GitHub Desktop.
Save hilda8519/69fcc6db1db7efb8e107 to your computer and use it in GitHub Desktop.
public boolean uniquechar(String str) {
if(str.length()>256)
return false;
if(str.length()=0)
return true;
boolean[] charset=new boolean[256];
for(int i=0;i<str.length;i++){
int val=str.charat(i);
if(char_set[val]){
return false;
}
else{
return true;
}
}
return true;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment