Connecting Tech Pros Worldwide Help | Site Map

How to input text and output binary

Newbie
 
Join Date: Nov 2009
Posts: 2
#1: 1 Week Ago
hello,

i need help on this, as i don't know how to do this.

i need to be able input a message text and the output will be binary form and consider that the header below:

layer4: application header-(binary value = 00)
layer3: transport header -(binary value = 01)
layer2: internetwork header - (binary value = 10)
layer1: network interface header - (binary value =11)

the length of the total message with all the header value has been set to 128 bits.

please help.
Newbie
 
Join Date: Nov 2009
Posts: 2
#2: 1 Week Ago

re: How to input text and output binary


anyone knows how to write the program above?
Needs Regular Fix
 
Join Date: Jul 2008
Posts: 380
#3: 1 Week Ago

re: How to input text and output binary


Specs are too vague - I don't understand what is expected as the output, and it also sounds like a homework.
Moderator
 
Join Date: Mar 2007
Location: North Bend Washington USA
Posts: 5,363
#4: 1 Week Ago

re: How to input text and output binary


Binary values 00, 01, 10 and 11 are integer values 0,1,2 and 3.

I don't see your problem.
Reply