Sha256: ee5774692468cff8af153e965937bac68ab934a2ea8a4a16dd5cf13dd3d4f2d4

Contents?: true

Size: 383 Bytes

Versions: 125

Compression:

Stored size: 383 Bytes

Contents

using System;
using System.Collections.Generic;

public class Isogram
{
    public static bool IsIsogram(string word)
    {
        var letters = new HashSet<char>();

        foreach (var c in word.ToLowerInvariant())
        {
            if (Char.IsLetter(c) && !letters.Add(c))
            {
                return false;
            }
        }

        return true;
    }
}

Version data entries

125 entries across 125 versions & 1 rubygems

Version Path
trackler-2.0.8.4 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.8.3 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.8.2 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.8.1 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.7.0 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.6.44 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.6.43 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.6.42 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.6.41 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.6.40 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.6.39 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.6.38 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.6.37 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.6.36 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.6.35 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.6.34 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.6.33 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.6.32 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.6.31 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.6.30 tracks/csharp/exercises/isogram/Example.cs