Integer calculation : Integer « Data Type « VB.Net Tutorial

VB.Net Tutorial
1. Language Basics
2. Data Type
3. Operator
4. Statements
5. Date Time
6. Class Module
7. Development
8. Collections
9. Generics
10. Attributes
11. Event
12. Stream File
13. GUI
14. GUI Applications
15. 2D Graphics
16. I18N Internationlization
17. Reflection
18. Regular Expressions
19. Security
20. Socket Network
21. Thread
22. Windows
23. XML
24. Database ADO.net
25. Design Patterns
Microsoft Office Word 2007 Tutorial
Java
Java Tutorial
Java Source Code / Java Documentation
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
C# / C Sharp
C# / CSharp Tutorial
ASP.Net
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
PHP
Python
SQL Server / T-SQL
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial » Data Type » Integer 
2. 2. 3. Integer calculation
 
 

public class Test
   public Shared Sub Main
        Dim As Integer

        ' try adding numbers...
        n = 16
        n += 10.23
        Console.WriteLine("Addition " & n)

        ' try subtracting numbers...
        n = 24
        n -= 2
        Console.WriteLine("Subtraction " & n)

        ' try multiplying numbers...
        n = 6
        n *= 10
        Console.WriteLine("Multiplication " & n)

        ' try dividing numbers...
        n = 12
        n /= 6
        Console.WriteLine("Division " & n)


   End Sub
End class

        
  
  




Addition 26
Subtraction 22
Multiplication 60
Division 2

 
2. 2. Integer
2. 2. 1. Define Integer variable and assign value
2. 2. 2. Add two integers together
2. 2. 3. Integer calculation
2. 2. 4. Swap two integers without using a third
2. 2. 5. MinValue and MaxValue of Integer
2. 2. 6. Parse Integer
2. 2. 7. Integer.GetType
2. 2. 8. Integer boolean calculation: Or, And, Xor, Not
2. 2. 9. Parse Integer variable and get hash code from Integer
2. 2. 10. Use Integer.CompareTo to compare two integers
2. 2. 11. Integer format: D10
2. 2. 12. Pass Integer to a function by reference
2. 2. 13. Pass Integer to a function by value
2. 2. 14. Compare Integer value in If statement
2. 2. 15. Integer OverflowException
2. 2. 16. Implicit conversion of an integer to a string
2. 2. 17. Explicit conversion of an integer to a string
ww___w_.ja__v___a__2_s_.c__o__m__ | Contact Us
Copyright 2003 - 08 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.