Article Categories
- All Categories
-
Data Structure
-
Networking
-
RDBMS
-
Operating System
-
Java
-
MS Excel
-
iOS
-
HTML
-
CSS
-
Android
-
Python
-
C Programming
-
C++
-
C#
-
MongoDB
-
MySQL
-
Javascript
-
PHP
Selected Reading
Byte.MaxValue Field in C#
The Byte.MaxValue field in C# is used to represent the largest possible value of a Byte.
Syntax
Following is the syntax −
public const byte MaxValue = 255;
Example
Let us now see an example to implement the Byte.MaxValue field −
using System;
public class Demo {
public static void Main(){
byte val;
val = Byte.MaxValue;
Console.WriteLine("Maximum Value (Byte) = "+val);
}
}
Output
This will produce the following output −
Maximum Value (Byte) = 255
Advertisements
