tags:

views:

125

answers:

2

Lately i have been messing around with bittorrent protocol. I fail to see the point in bencoding files other than giving me headache in parsing them? What advantages does it have? Why not use xml?

/sarcasm

A: 

Developers love to reinvent the wheel.

Evert
+3  A: 

For one thing, I'm pretty sure bencoding is more space-efficient than equivalent XML.

Hank Gay
Hank is right - it's much, much more space-efficient. Even putting the data in an XML file with single letter tags would nearly double the size of the tracker response. And, to be honest, I don't think XML wasn't nearly as big a standard back when they defined the bittorrent stuff.
Ben Gotow