بسم الله الر حمن الر حيم

Below is some base difference Data types of between C#, VB .Net and C++ language:

 

 

VB .Net

C++

C#

(Unknown data)
n/a

(Unknown data)

VARIANT

(Unknown data)
Derive type

(Decimal)
Decimal

0 through +/-79,228,162,514,264,337,593,543,950,335 (+/-7.9…E+28) with no decimal point; 0 through +/-7.9228162514264337593543950335 with 28 places to the right of the decimal;

smallest nonzero number is +/-0.0000000000000000000000000001 (+/-1E-28)

(Decimal)

DECIMAL
(
+79,228,162,514,264,337,593,543,950,335 to -79,228,162,514,264,337,593,543,950,335
)

(Decimal)
decimal
(

±1.0 × 10−28 to ±7.9 × 1028

)

(Date)
Date
(

0:00:00 (midnight) on January 1, 0001 through 11:59:59 PM on December 31, 9999

)

(Date)
DATE
(Date)
DateTime
(00:00:00.0000000, January 1, 0001 to 23:59:59.9999999, December 31, 9999, exactly one 100-nanosecond tick before 00:00:00, January 1, 10000)

(SBCS character

(1 byte))
n/a

(SBCS character (1 byte))

signed char

__int8

(

–128 to 127

)

(SBCS character

(1 byte))

n/a

(Unicode character (2 bytes))

Char
(

0 through 65535 (unsigned)

)

(Unicode character (2 bytes))

wchar_t

(

0 to 65,535

)

(Unicode character (2 bytes))

char
(

U+0000 to U+ffff

)

(Unicode character sequence)
String
(

0 to approximately 2 billion Unicode characters

)

(Unicode character sequence)

wchar_t*

(Unicode character sequence)
string

(Boolean (platform dependent))

Boolean

(True or False)

(Boolean (platform dependent))

VARIANT_BOOL

(false or true)

(Boolean (platform dependent))

bool
(true OR false)

(1 byte)

SByte
(

-128 through 127 (signed)

)

(1 byte)

signed char

(

–128 to 127

)

(1 byte)

sbyte

(

-128 to 127

)

(2 bytes)

Short
(-32,768 through 32,767.)

(2 bytes)

signed short int

__int16

(

–32,768 to 32,767

)

(2 bytes)

short

(

-32,768 to 32,767

)

(4 bytes)

Integer
(

-2,147,483,648 through 2,147,483,647 (signed)

)

(4 bytes)

long, (long int, signed long int)

(

–2,147,483,648 to 2,147,483,647

)

(4 bytes)

int

(

-2,147,483,648 to 2,147,483,647

)

(8 bytes)

Long
(

-9,223,372,036,854,775,808 through 9,223,372,036,854,775,807 (9.2…E+18 ) (signed)

)

(8 bytes)

__int64

(

–9,223,372,036,854,775,808 to 9,223,372,036,854,775,807

)

(8 bytes)

long

(

-9,223,372,036,854,775,808 to 9,223,372,036,854,775,807

)

1 byte unsigned

Byte
(

0 through 255 (unsigned)

)

1 byte unsigned

BYTE

bool

(

0 to 255

)

1 byte unsigned

byte

(

0 to 255

)

(2 bytes unsigned)

UShort
(0 through 65,535 (unsigned))

(2 bytes unsigned)

unsigned short

(

0 to 65,535

)

(2 bytes unsigned)

ushort

(

0 to 65,535

)

(4 bytes unsigned)

UInteger
(

0 through 4,294,967,295 (unsigned)

)

(4 bytes unsigned)

unsigned int and unsigned long

(

0 to 4,294,967,295

)

&

(

0 to 4,294,967,295

)

(4 bytes unsigned)

uint

(

0 to 4,294,967,295

)

(8 bytes unsigned)

ULong
(

0 through 18,446,744,073,709,551,615 (1.8…E+19 ) (unsigned)

)

(8 bytes unsigned)

unsigned__int64

(

0 to 18,446,744,073,709,551,615

)

(8 bytes unsigned)

ulong

(

0 to 18,446,744,073,709,551,615

)

(4 bytes floating point)

Single
(

-3.4028235E+38 through -1.401298E-45 for negative values;

1.401298E-45 through 3.4028235E+38 for positive values

)

(4 bytes floating point)

float

(

3.4E +/- 38 (7 digits)

)

(4 bytes floating point)

float

(

±1.5 × 10−45 to ±3.4 × 1038

)

(8 bytes floating point)

Double
(

-1.79769313486231570E+308 through -4.94065645841246544E-324 for negative values;

4.94065645841246544E-324 through 1.79769313486231570E+308 for positive values

)

(8 bytes floating point)

double

(

1.7E +/- 308 (15 digits)

)

(8 bytes floating point)

double

(

±5.0 × 10−324 to ±1.7 × 10308

)

Alhamdulillah, semoga bermanfaat,,,

About ifqo

Kepingin melawan arus, agar tidak tenggelam,,,

Tinggalkan Komentar/Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s