Categories > Coding > C# >
C#Password Generator
Posted
Hi i saw a post on a python password Generator so I decided to make one in C#
Code:
Random random = new Random();
string[] characters = new[] { "P", "L", "A", "j", "d", "b", "q", "g", "u", "e", "w", "k", "l", "p", "l", "h", "v", "i", "m", "n", "f", "z", "a", "2", "5", "9", "1", "7", "8", "3", "4", "6", "&", "@", "#", "!", "^", ":", "=", "$" };
while (true)
{
Console.Write("\nPassword length:");
var passwordLength = Convert.ToInt32(Console.ReadLine());
Console.WriteLine();
for (int i = 0; i < passwordLength; i++)
{
Console.Write(characters[random.Next(characters.Length)]);
}
Console.Beep();
}
Replied
this code makes me want to do seppuku
Cancel
Post
Replied
Cancel
Post
"Questionable intellegence, but I like the mystery" - CubeFaces
https://cdn.discordapp.com/attachments/1136067487847415848/1138948596679589898/sig.png
Replied
please stop making password generators
Cancel
Post
https://cdn.discordapp.com/attachments/1023423265160560745/1132948683747500092/Frame_12x.png
Users viewing this thread:
( Members: 0, Guests: 1, Total: 1 )
Cancel
Post