equal
deleted
inserted
replaced
|
1 val my_urls = """urbanc""".r |
|
2 |
|
3 def crawl(url: String, n: Int) : Unit = { |
|
4 if (n == 0) () |
|
5 else if (my_urls.findFirstIn(url) == None) () |
|
6 else { |
|
7 println("Visiting: " + n + " " + url) |
|
8 for (u <- get_all_URLs(get_page(url))) crawl(u, n - 1) |
|
9 } |
|
10 } |