PHP-Code:
static class RandomString {
        static 
string[] chars = {"A""B""C""D""E""F""G""H""I""J""K""L""M""N""O""P""Q""R""S""T""U""V",
                                 
"W""X""Y""Z"};
        static 
Random random = new Random();
        public static 
string Generate(int length) {
            
string toReturn "";

            for (
int i 0lengthi++) {
                
int value random.Next(026);
                
toReturn += value == chars[value] : chars[value].ToLower();
            }
            return 
toReturn;
        }
    }