TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

The most fun eight Python lines I've written

15 pointsby for_i_in_rangeover 10 years ago

3 comments

fooneover 10 years ago
BTW, the random module has a "choice" function, which takes a sequence and returns a randomly chosen element from it. So instead of "result[randrange(len(result))]" you could have "choice(result)"
lexnayover 10 years ago
is this a porn comments scraper? The only thing more diabolical would be a youtube comments scraper
coppolaemilioover 10 years ago
Thanks for sharing! hahahah xD