Sha256: a2810da81ce3fa6b57037cf56ebbd248d7759a6e349c9c6c2e2651c95d6af163

Contents?: true

Size: 198 Bytes

Versions: 272

Compression:

Stored size: 198 Bytes

Contents

module Hamming

let compute (strand1:string) (strand2:string) = 
    Array.zip (strand1.ToCharArray()) (strand2.ToCharArray()) 
    |> Array.filter (fun (c1, c2) -> c1 <> c2) 
    |> Array.length

Version data entries

272 entries across 272 versions & 1 rubygems

Version Path
trackler-2.0.0.1 tracks/fsharp/exercises/hamming/Example.fs
trackler-2.0.0.0 tracks/fsharp/exercises/hamming/Example.fs
trackler-1.0.4.1 tracks/fsharp/exercises/hamming/Example.fs
trackler-1.0.4.0 tracks/fsharp/exercises/hamming/Example.fs
trackler-1.0.3.0 tracks/fsharp/exercises/hamming/Example.fs
trackler-1.0.2.1 tracks/fsharp/exercises/hamming/Example.fs
trackler-1.0.2.0 tracks/fsharp/exercises/hamming/Example.fs
trackler-1.0.1.2 tracks/fsharp/exercises/hamming/Example.fs
trackler-1.0.1.1 tracks/fsharp/exercises/hamming/Example.fs
trackler-1.0.1.0 tracks/fsharp/exercises/hamming/Example.fs
trackler-1.0.0.1 tracks/fsharp/exercises/hamming/Example.fs
trackler-1.0.0 tracks/fsharp/exercises/hamming/Example.fs