And, Or, Xor and Not on Integer : Integer « Data Types « VB.Net






And, Or, Xor and Not on Integer

And, Or, Xor and Not on Integer
   
Imports System

Public Class MainClass

    Shared Sub Main(ByVal args As String())
       Dim x As Integer = 5
       Dim y As Integer = 7

       Dim andValue As Boolean
       Dim orValue As Boolean
       Dim xorValue As Boolean
       Dim notValue As Boolean

       andValue = x = 3 And y = 7
       orValue = x = 3 Or y = 7
       xorValue = x = 3 Xor y = 7
       notValue = Not x = 3

       Console.WriteLine("x = 3 And y = 7. {0}", andValue)
       Console.WriteLine("x = 3 Or y = 7. {0}", orValue)
       Console.WriteLine("x = 3 Xor y = 7. {0}", xorValue)
       Console.WriteLine("Not x = 3. {0}", notValue)
    End Sub
End Class

           
         
    
    
  








Related examples in the same category

1.Compare Integer value and output their relationCompare Integer value and output their relation
2.Integer Initialize and assignmentInteger Initialize and assignment
3.Integer calculationInteger calculation
4.Define and use Array IntegerDefine and use Array Integer
5.Integer Value DemoInteger Value Demo
6.Integer: add, subtract, multiply and divideInteger: add, subtract, multiply and divide
7.Concatenate string and intConcatenate string and int
8.Append Integer data type values to a StringBuilder object.
9.Generic and nongeneric versions of the CompareTo method for Int16 value
10.Generic and nongeneric versions of the CompareTo method for Int32 value
11.Generic and nongeneric versions of the CompareTo method for Int64 value
12.Use the Sign(Integer) method to determine the sign of an Integer value and display it to the console.
13.Byte Structure Represents an 8-bit unsigned integer.
14.Convert Integer to Byte with CByte
15.Convert Integer to Byte with Convert
16.Parse a negative integer value
17.Int32 Structure Represents a 32-bit signed integer.
18.Integer variables
19.Int32 CompareTo Method
20.Int32 Equals Method
21.Int32.MaxValue Field Represents the largest possible value of an Int32. This field is constant.
22.Int32.Parse Method Converts string to 32-bit signed integer equivalent.
23.Int32.Parse Method (String, NumberStyles) Converts string to 32-bit signed integer equivalent.
24.Int32 Structure Represents a 32-bit signed integer.