What do you want to save?
Add Code snippet
New code examples
-
-
Java 2021-10-06 05:10:02
string frequency of characters in java
+++METHOD WITH NONDUP+++ public static String FrequencyOfChars(String str) { String nonDup = ""; for(int i=0; i < str.length(); i++) if(!nonDup.contains(""+str.charAt(i))) nonDup+= ""+str.charAt(i); String expectedRe... Add solution -
-
Java 2021-10-04 00:23:02
Write a Java program to count the letters numbers and other characters of an input string.
public static String countLetter(String str){ String abc=str; int a=0,b=0; while(str.length()>0){ int i=0; String ch=str.substring(i,i+1); if(ch.matches(".*[a-zA-Z].*")){ a++; }else if (... Add solution -
Javascript 2021-09-30 02:59:06
regex to remove spaces
//.. return str.replace(/\s/g, ''); //.. Add solution
Best helpers
Ranking is empty