Add threading and nesting for lab#2.

TODO:
 * add proper output (rewrite output concurrency)
 * add tests
 * add relative urls support
 * change input format (1 url => file of urls)