Sha256: c433311e1efd866e939d884ed1a789fa95715e357f912ae3eebeca326378c93c

Contents?: true

Size: 154 Bytes

Versions: 228

Compression:

Stored size: 154 Bytes

Contents

class Phrase {
  String input 

  def Phrase(s) {
    input = s
  }

  def wordCount() {
    input.toLowerCase().findAll(/[\w']+/).countBy { it }  
  }
}

Version data entries

228 entries across 228 versions & 1 rubygems

Version Path
trackler-2.2.1.10 tracks/groovy/exercises/word-count/Example.groovy
trackler-2.2.1.9 tracks/groovy/exercises/word-count/Example.groovy
trackler-2.2.1.8 tracks/groovy/exercises/word-count/Example.groovy
trackler-2.2.1.7 tracks/groovy/exercises/word-count/Example.groovy
trackler-2.2.1.6 tracks/groovy/exercises/word-count/Example.groovy
trackler-2.2.1.5 tracks/groovy/exercises/word-count/Example.groovy
trackler-2.2.1.4 tracks/groovy/exercises/word-count/Example.groovy
trackler-2.2.1.3 tracks/groovy/exercises/word-count/Example.groovy
trackler-2.2.1.2 tracks/groovy/exercises/word-count/Example.groovy
trackler-2.2.1.1 tracks/groovy/exercises/word-count/Example.groovy
trackler-2.2.1.0 tracks/groovy/exercises/word-count/Example.groovy
trackler-2.2.0.6 tracks/groovy/exercises/word-count/Example.groovy
trackler-2.2.0.5 tracks/groovy/exercises/word-count/Example.groovy
trackler-2.2.0.4 tracks/groovy/exercises/word-count/Example.groovy
trackler-2.2.0.3 tracks/groovy/exercises/word-count/Example.groovy
trackler-2.2.0.2 tracks/groovy/exercises/word-count/Example.groovy
trackler-2.2.0.1 tracks/groovy/exercises/word-count/Example.groovy
trackler-2.2.0.0 tracks/groovy/exercises/word-count/Example.groovy
trackler-2.1.0.55 tracks/groovy/exercises/word-count/Example.groovy
trackler-2.1.0.54 tracks/groovy/exercises/word-count/Example.groovy