0

I will be grateful for your help (I am among those non-comfy students): I am struggling to understand what type of input I am dealing with when writing the parse function, i.e. what the line could look like? Will the input look like

GET /somesite.extension [? possible query] HTTP/1.1

and I will have to extract parts from it to fill in abs_path and query, or am I getting something like

http://whateveritcanbe.com/whateverelse/etc?

or even something else? The question is whether I am getting a request-line in its pure form, or do I have to first create that request-line from whatever the input could look like, and than extract abs_path and query? Thank you!

1

From the instructions:

Ensure that request-line (which is passed into parse as line) ......

Therefore, your first assumption is a good starting point.

1
  • thank you for your answer!
    – Vitale
    Apr 30 '16 at 6:40

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .