0
0
KPKonrad Psiuk
The following code uses the Flags attribute to identify the type of integer that is being manipulated. The int type is used because it is the most primitive data type in the C# language.
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using System.IO; using System.Threading.Tasks.Dataflow; namespace ConsoleApp1 { internal class Program { static void Main(string[] args) { var e = EEE.five; Console.WriteLine((e & EEE.five)==EEE.four); //false Console.WriteLine(Convert.
namespace ConsoleApp1
{
internal class Program
{
static void Main(string[] args)
{
var e = EEE.five;
Console.WriteLine((e & EEE.five)==EEE.four); //false
}
}
[Flags]
enum EEE
{
one = 0,
two = 1,
three = 1 << 1,
four = 1 << 2,
five = 1 << 3
}
}