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
Convert.ToUInt64 Method in C#
Use the Convert.ToUInt64() method to convert a specified value to a 64-bit unsigned integer.
The following is our char.
char ch = 'a';
Now, let’s convert it to a 64-bit unsigned integer.
ulong res; res = Convert.ToUInt64(ch);
Here is the complete example.
Example
using System;
public class Demo {
public static void Main() {
char ch = 'a';
ulong res;
res = Convert.ToUInt64(ch);
Console.WriteLine("Converted char value '{0}' to {1}", ch, res);
}
}
Output
Converted char value 'a' to 97
Advertisements
