Blogs

Category: none



A few tips for production Golang app

27 Sep 2020    golang

After writing Golang code for some time, I found that Golang is a good language. Especially after coming from Python world, the inferred typing in most cases but explicit typing is really good for reading, understanding a moderate to big codebase. Exception handling requires some get-used-to but it is good enough now with error wrapping and unwrapping. Lack of generic is a pain point but not unmanageable. Language is good but human effort is still needed to make best use of it.

Using Python to analyze PE ratio and stock market performance

20 Feb 2018    data

Use Python to extract, clean and plot PE ratio and prices of SPY index as an indicator of American stock market.

Play a fun functional programming game

07 Feb 2018    python

Functional programming is cool and fun – at least it should be. But if I look at the definition on Wikipedia:

豆瓣高分图书推荐

30 Oct 2017    reading

Post multipart form data using Python requests

30 Oct 2017    python

Requests is a great library for networking in Python with its friendly APIs and rich features. But today when I try to send a POST request to a website, using multipart form encoding, but without files, I got stuck and did not find my luck in the documentation either.

Calkin Wilf Sequence on codefights

15 Oct 2017    programming

Codefights is a website for practicing and brushing up on programming skills. Recently I have been working on its Python arcade, trying to learn more Python language special features. Well, generally I think most questions are well-thought but are not problems for me – I am confident about my knowledge of Python so far. However, I did get stuck on one question in the generator section.

Chrome not showing up on Ubuntu 14.04

30 Sep 2017    software

So one day after I upgraded Chrome for my old Ubuntu 14.04 machine and I could not launch the browser. Well, if I do ps aux | grep chrome I can still find the process running but I could not see anything. A browser that is not viewable is not a browser anymore and not useful at all. The process is indeed running – so it must be the display problem.