How many bytes?

View previous topic View next topic Go down

Solved How many bytes?

Post by Lance(HAOH) on Mon Dec 07, 2009 3:00 am

Could anyone please explain to me why this uses 32 bytes? Shouldn't 8 bits make 1 byte
and this should make up 16 bytes?

0000000: 0100 4d61 696e 2053 742e 0000 0000 0000 ..Main St.......

0000016: 0000 0000 0000 0000 0000 0000 0000 0000 ................

0000032: 1900 536f 7574 6820 5374 2e00 0000 0000 ..South St......

0000048: 0000 0000 0000 0000 0000 0000 0000 0000 ................

Lance(HAOH)
Intermediate
Intermediate

Status :
Online
Offline

Posts : 138
Joined : 2008-12-12
Gender : Male
OS : Windows XP Professional, Windows 7 Enterprise, Windows 8 Professional WMC, Ubuntu Linux

View user profile

Back to top Go down

Solved Re: How many bytes?

Post by skilldegree on Mon Dec 07, 2009 10:22 am

Um not 100% sure, but that looks like hex to me. so each individual number would take up 1 byte?

skilldegree
Intermediate
Intermediate

Status :
Online
Offline

Posts : 55
Joined : 2009-08-16
Gender : Male
OS : Win7 x64 Ultimate

View user profile

Back to top Go down

Solved Re: How many bytes?

Post by Lance(HAOH) on Tue Dec 08, 2009 9:27 am

Yup. The chunk of numbers is hexadecimal view from a hex-editor. But each individual number is called a bit. 8 bits make a byte. But I am confused... The book which I took the sample from wrote that this was a 32 bit string. Could someone please help to clarify my doubts?

Lance(HAOH)
Intermediate
Intermediate

Status :
Online
Offline

Posts : 138
Joined : 2008-12-12
Gender : Male
OS : Windows XP Professional, Windows 7 Enterprise, Windows 8 Professional WMC, Ubuntu Linux

View user profile

Back to top Go down

Solved Re: How many bytes?

Post by Doctor Inferno on Tue Dec 08, 2009 10:11 am

Hello,

Each hexadecimal digit represents four binary digits also known as bits. So ignoring the equation of 8 bits = 1 bytes, there are 32 bytes as counted. Shown in bold:

0000000: 0100 4d61 696e 2053 742e 0000 0000 0000 ..Main St.......

0000016: 0000 0000 0000 0000 0000 0000 0000 0000 ................

0000032: 1900 536f 7574 6820 5374 2e00 0000 0000 ..South St......

0000048: 0000 0000 0000 0000 0000 0000 0000 0000 ................


Please be a GeekPolice fan on Facebook!



Have we helped you? Help us! | Doctor by day, ninja by night.

Doctor Inferno
Administrator
Administrator

Status :
Online
Offline

Posts : 12017
Joined : 2007-12-26
Gender : Male
OS : Windows 7 Home Premium and Ultimate X64

View user profile

Back to top Go down

Solved Re: How many bytes?

Post by Lance(HAOH) on Wed Dec 09, 2009 3:15 am

Thanks for your help! Thank You!

Lance(HAOH)
Intermediate
Intermediate

Status :
Online
Offline

Posts : 138
Joined : 2008-12-12
Gender : Male
OS : Windows XP Professional, Windows 7 Enterprise, Windows 8 Professional WMC, Ubuntu Linux

View user profile

Back to top Go down

Solved Re: How many bytes?

Post by Doctor Inferno on Wed Dec 09, 2009 3:41 am

Glad I could help! Smile


Please be a GeekPolice fan on Facebook!



Have we helped you? Help us! | Doctor by day, ninja by night.

Doctor Inferno
Administrator
Administrator

Status :
Online
Offline

Posts : 12017
Joined : 2007-12-26
Gender : Male
OS : Windows 7 Home Premium and Ultimate X64

View user profile

Back to top Go down

View previous topic View next topic Back to top

- Similar topics

 
Permissions in this forum:
You cannot reply to topics in this forum