fork download
  1. using System;
  2.  
  3. public class Test
  4. {
  5.  
  6. enum enWalls{WallNorth = 0x01,WallEast = 0x02,WallSouth = 0x04,WallWest = 0x08};
  7. public static void Main()
  8. {
  9. const uint AllWalls = (uint)enWalls.WallNorth+(uint)enWalls.WallEast+
  10. (uint)enWalls.WallSouth+(uint)enWalls.WallWest;
  11. uint[][] mz = new uint[100][];
  12. for(int i=0; i<100; ++i){
  13. mz[i] = new uint[100];
  14. for(int j=0; j<100; mz[i][j++] = AllWalls);
  15. }
  16. Random rnd = new Random();
  17. uint rn = rnd.Next(0,3);
  18. Console.WriteLine("Wall a = {0}, wall b = {1}",1<<rn,1<<((rn+2)%4));
  19.  
  20. }
  21. }
Compilation error #stdin compilation error #stdout 0s 0KB
stdin
Standard input is empty
compilation info
prog.cs(17,22): error CS0266: Cannot implicitly convert type `int' to `uint'. An explicit conversion exists (are you missing a cast?)
prog.cs(18,65): error CS0019: Operator `<<' cannot be applied to operands of type `int' and `uint'
prog.cs(18,71): error CS0019: Operator `<<' cannot be applied to operands of type `int' and `uint'
Compilation failed: 3 error(s), 0 warnings
stdout
Standard output is empty