mrlonelyjtr's blog

写BUG的程序猿


  • Home

  • Categories

  • Archives

  • Tags

  • Search

[LintCode] Problem 551 - Nested List Weight Sum

Posted on 2019-08-17 | In Algorithm , LintCode
Given a nested list of integers, return the sum of all integers in the list weighted by their depth. Each element is either an integer, or a list – wh ...
Read more »

[LintCode] Problem 804 - Number of Distinct Islands II

Posted on 2019-08-17 | In Algorithm , LintCode
Given a non-empty 2D array grid of 0’s and 1’s, an island is a group of 1’s (representing land) connected 4-directionally (horizontal or vertical.) Yo ...
Read more »

[LintCode] Problem 434 - Number of Islands II

Posted on 2019-08-17 | In Algorithm , LintCode
Given a n,m which means the row and column of the 2D matrix and an array of pair A(size k). Originally, the 2D matrix is all 0 which means there is on ...
Read more »

Cookies池的搭建

Posted on 2019-08-17 | In Web Crawler
Cookie池 存储模块负责存储每个账号的用户名密码以及每个账号对应的Cookies信息,同时还需要提供一些方法来实现方便的存取操作。 生成模块负责生成新的Cookies。此模块会从存储模块逐个拿取账号的用户名和密码,然后模拟登录目标页面,判断登录成功,就将Cookies返回并交给存储模块存储。 ...
Read more »

代理池的维护

Posted on 2019-08-17 | In Web Crawler
代理池 存储模块使用Redis的有序集合,用来做代理的去重和状态标识,同时它也是中心模块和基础模块,将其他模块串联起来。 获取模块定时从代理网站获取代理,将获取的代理传递给存储模块,并保存到数据库。 检测模块定时通过存储模块获取所有代理,并对代理进行检测,根据不同的检测结果对代理设置不同 ...
Read more »

[LeetCode] Problem 672 - Bulb Switcher II

Posted on 2019-08-15 | In Algorithm , LeetCode
There is a room with n lights which are turned on initially and 4 buttons on the wall. After performing exactly m unknown operations towards buttons, ...
Read more »

[LeetCode] Problem 319 - Bulb Switcher

Posted on 2019-08-15 | In Algorithm , LeetCode
There are n bulbs that are initially off. You first turn on all the bulbs. Then, you turn off every second bulb. On the third round, you toggle every ...
Read more »

[LeetCode] Problem 275 - H-Index II

Posted on 2019-08-15 | In Algorithm , LeetCode
Given an array of citations sorted in ascending order (each citation is a non-negative integer) of a researcher, write a function to compute the resea ...
Read more »

[LeetCode] Problem 274 - H-Index

Posted on 2019-08-15 | In Algorithm , LeetCode
Given an array of citations (each citation is a non-negative integer) of a researcher, write a function to compute the researcher’s h-index. According ...
Read more »

[POJ] Problem 3782 - Equal Sum Partitions

Posted on 2019-08-15 | In Algorithm , POJ
An equal sum partition of a sequence of numbers is a grouping of the numbers (in the same order as the original sequence) in such a way that each grou ...
Read more »
1…212223…78
mrlonelyjtr

mrlonelyjtr

间歇性踌躇满志,持续性混吃等死

780 posts
18 categories
18 tags
Github
© 2020 mrlonelyjtr
Powered by Hexo
Theme - NexT.Pisces