using System.Collections.Generic;
using System.Threading.Tasks;
for (int i = 0; i < 10; i++)
Console.WriteLine(GetRandom());
private static uint GetRandom()
for (int i = 0; i < 10; i++)
Seed = Round(RoR(Seed, 8), Seed);
private static uint Round(uint input, uint key)
var substitution = BitConverter.GetBytes(input);
substitution[0] = sBoxes[0][substitution[0]];
substitution[1] = sBoxes[1][substitution[1]];
substitution[2] = sBoxes[2][substitution[2]];
substitution[3] = sBoxes[3][substitution[3]];
return BitConverter.ToUInt32(substitution, 0);
private static uint RoR(uint value, int count)
return (value >> count) | (value << (32 - count));
new byte[] {151,254,44,53,51,2,26,181,122,21,45,78,243,154,60,116,43,114,127,120,155,162,111,31,89,166,204,101,113,157,139,211,115,216,123,88,73,125,142,179,130,80,145,107,74,143,11,248,148,240,84,245,13,219,140,54,68,134,119,161,193,27,225,83,233,231,237,92,61,205,102,251,9,126,25,227,236,75,109,246,217,252,239,203,214,23,159,106,48,221,110,7,253,222,212,208,4,16,35,70,247,228,105,19,167,12,128,192,241,146,112,1,163,65,90,249,40,223,136,10,190,209,87,3,94,30,230,178,220,183,64,207,187,185,174,85,32,117,0,200,29,170,176,226,59,18,229,103,22,99,36,232,186,133,196,169,5,97,150,165,77,49,250,164,177,81,24,156,71,189,56,66,118,197,201,76,137,37,33,147,188,15,152,149,244,180,79,141,95,135,8,195,131,168,215,158,108,47,41,235,172,255,173,160,213,132,39,171,96,91,153,38,93,86,20,58,242,199,184,121,182,50,191,100,72,218,14,144,138,238,202,129,17,67,46,63,34,104,206,57,6,52,28,175,62,69,210,234,194,124,98,42,55,198,224,82},
new byte[] {234,82,208,51,148,3,125,193,188,202,251,212,39,75,71,130,161,118,246,90,203,180,57,109,87,2,15,230,78,32,50,138,248,195,233,83,68,111,122,253,187,147,65,11,137,144,134,176,140,167,53,25,98,220,72,1,219,110,169,200,74,46,135,93,47,92,6,44,224,205,166,76,194,113,12,95,157,29,59,81,141,240,104,38,201,34,77,121,192,91,9,165,252,96,218,61,115,54,143,97,124,221,249,62,244,223,170,178,139,102,7,69,204,80,186,217,159,58,24,254,154,146,182,131,4,31,250,116,108,67,48,132,26,63,40,41,45,88,238,189,55,127,19,247,22,231,214,112,43,101,206,172,133,155,105,149,16,235,70,191,20,209,225,211,242,37,27,171,73,228,123,245,36,79,60,207,117,232,119,18,8,175,190,129,14,241,99,86,255,173,100,213,163,164,142,103,128,152,183,23,227,17,10,181,184,150,107,156,120,158,52,239,198,49,136,197,179,162,145,126,64,160,89,216,222,229,85,21,0,185,94,226,84,215,168,35,174,13,28,106,42,56,243,30,153,196,237,33,177,199,210,5,66,236,114,151},
new byte[] {174,86,182,73,1,206,168,52,50,31,65,27,29,42,88,151,189,170,227,119,128,98,19,138,130,218,95,114,221,18,4,203,214,92,220,30,233,246,111,164,197,70,105,190,16,136,38,83,122,7,75,67,43,198,39,110,53,243,85,13,61,80,14,251,186,159,192,236,8,219,157,205,33,196,201,215,76,209,137,228,208,25,177,87,194,57,176,109,181,180,253,51,173,117,10,2,93,232,34,204,185,255,62,226,9,71,254,100,45,148,245,28,213,222,163,167,240,81,141,127,211,82,59,72,172,108,225,20,94,58,5,247,166,212,97,242,153,115,125,217,112,104,162,146,169,6,44,74,101,91,195,24,237,149,142,231,48,121,124,207,147,21,249,244,156,47,238,135,171,160,229,49,210,158,23,239,35,191,139,55,66,188,223,134,126,145,40,89,230,113,140,216,252,133,131,106,56,54,161,152,99,234,118,3,12,154,68,32,90,250,144,64,248,84,143,78,116,63,150,107,96,175,77,36,103,0,199,183,17,241,102,202,193,224,22,129,165,155,120,26,37,123,69,41,179,187,178,60,11,235,46,15,184,200,132,79},
new byte[] {38,70,244,63,71,252,13,95,58,219,30,75,235,243,39,153,233,163,156,223,220,137,103,64,85,113,226,78,212,136,18,231,100,158,164,150,178,248,115,33,199,106,107,181,151,214,161,240,187,73,188,140,255,241,139,42,236,6,195,217,11,250,120,247,72,149,228,21,45,169,102,253,83,86,157,167,114,92,25,148,12,109,4,145,242,111,129,101,135,132,117,133,8,43,130,27,5,222,221,0,216,168,79,89,246,123,170,239,48,56,203,110,134,32,14,105,202,37,141,254,19,172,194,104,142,44,60,82,53,26,28,162,81,67,46,154,36,10,171,2,215,183,91,59,200,97,94,17,1,77,24,66,146,196,143,249,189,61,93,112,76,166,131,116,50,23,225,121,209,182,144,128,227,176,119,99,198,108,49,175,126,229,80,52,40,237,177,208,218,160,55,173,51,87,9,15,230,193,35,88,41,62,159,185,125,152,207,74,31,210,54,165,65,190,186,205,68,206,122,191,90,3,180,251,127,245,179,29,201,69,238,204,47,20,155,192,118,224,147,34,234,211,7,138,124,197,232,96,57,84,184,16,98,22,213,174}