Encode and encode bencoded data