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.24 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.8.23 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.8.22 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.8.21 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.8.20 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.8.19 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.8.18 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.8.17 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.8.16 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.8.15 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.8.14 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.8.13 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.8.12 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.8.11 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.8.10 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.8.9 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.8.8 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.8.7 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.8.6 tracks/csharp/exercises/isogram/Example.cs
trackler-2.0.8.5 tracks/csharp/exercises/isogram/Example.cs