MCPcopy Create free account
hub / github.com/careercup/ctci / main

Method main

java/Chapter 1/Question1_5/Question.java:99–108  ·  view source on GitHub ↗
(String[] args)

Source from the content-addressed store, hash-verified

97 }
98
99 public static void main(String[] args) {
100 String str = "abbccccccde";
101 int c = countCompression(str);
102 String str2 = compressAlternate(str);
103 String t = compressBetter("");
104 System.out.println("Compression: " + t);
105 System.out.println("Old String (len = " + str.length() + "): " + str);
106 System.out.println("New String (len = " + str2.length() + "): " + str2);
107 System.out.println("Potential Compression: " + c);
108 }
109}

Callers

nothing calls this directly

Calls 4

countCompressionMethod · 0.95
compressAlternateMethod · 0.95
compressBetterMethod · 0.95
lengthMethod · 0.45

Tested by

no test coverage detected