Class 10 Computer Science — Asking and answering over the web
Say what travels out in a request and what comes back in the answer, read the data an address carries, and follow what a browser does with the number it is answered with.
Name: ________________________
1.An address ends with the piece shown below. How many name-and-value pairs is it carrying?
?topic=lists&sort=new&page=3
2.A browser asks for a page and the answer that comes back is 500. Whose end has the problem?
- a) The browser that asked
- b) The reader's own connection
- c) The machine holding the page
- d) Nobody's — 500 means the page is there but empty
3.A browser asks for one HTML file and six pictures. Five of the seven answers come back 200, and the other two come back 404. How many pieces of the page are missing?
4.Match each status number to what the answer carrying it is saying.
- 200
- 404
- 301
- 500
- 403
- Here is what you asked for
- It has moved — ask again at this other address
- There is nothing here by that name
- It is here, but you are not allowed to see it
- Something went wrong at this end while I was answering
5.A form has four boxes. All four are filled in and sent as part of the address, on a path of /search. How many question marks does the address that goes out have in it?
6.Put these addresses in order of how many name-and-value pairs each one carries, fewest first.
- /find?q=pen
- /notices/exam/timetable?term=summer&stream=science
- /s?a=1&b=2&c=3
- /search?item=pen&size=large&count=4&page=2
7.A browser sent ten requests for one page. Eight were answered 200, one was answered 301 and one was answered 404. The browser then follows the 301 and is answered 200. How many requests has it sent altogether by that point?
8.A form sends three answers as part of the address. One more box is then added to the form and filled in as well. How many ampersands does the address carry now?
Answer key — Class 10 Computer Science — Asking and answering over the web
- 1. 3
- 2. c) The machine holding the page
- 3. 2
- 4. 200 → Here is what you asked for; 404 → There is nothing here by that name; 301 → It has moved — ask again at this other address; 500 → Something went wrong at this end while I was answering; 403 → It is here, but you are not allowed to see it
- 5. 1
- 6. 1. /find?q=pen 2. /notices/exam/timetable?term=summer&stream=science 3. /s?a=1&b=2&c=3 4. /search?item=pen&size=large&count=4&page=2
- 7. 11
- 8. 3