mirror of
https://github.com/Smaug123/dotnet-classical-ciphers
synced 2025-10-05 12:38:40 +00:00
14 lines
348 B
Forth
14 lines
348 B
Forth
namespace CipherSuite.Test
|
|
|
|
[<RequireQualifiedAccess>]
|
|
module String =
|
|
|
|
let stripNonAlpha (s : string) =
|
|
s.ToCharArray ()
|
|
|> Array.choose (fun c ->
|
|
let c = System.Char.ToUpper c
|
|
let shifted = int c - 65
|
|
if shifted >= 0 && shifted < 26 then Some c else None
|
|
)
|
|
|> System.String
|