Log inSign up
Log inSign up
Lu Pan
744 posts
Lu Pan profile banner
@uvdn7

Lu Pan

@uvdn7
Working on distributed systems at Facebook. “uvdn7” is “lupan” rotated by 180.
Boston
uvdn7.github.io
Joined March 2010
264 Following
505 Followers
RepliesRepliesRepostsRepostsMediaMedia

Lu Pan’s posts

Log in or sign up for X

See what’s happening and join the conversation

Continue with phone
or
Log in with username or email
Terms·Privacy·Cookies·Accessibility·Ads Info·© 2026 X Corp.
  • @uvdn7
    Lu Pan
    @uvdn7
    Jul 14, 2025
    A really cool small piece of integer division code in `folly::BucketedTimeSeries` – uvdn7.github.io/bucketed-time-….
    uvdn7.github.io
    Integer Division in Bucketed Time Series
    This post is about a cool piece of integer math code in folly::BucketedTimeSeries.
    1
  • @uvdn7
    Lu Pan
    @uvdn7
    Jul 11, 2025
    I wrote this post on the mental model for C++ coro in March, and found myself referring back to it often. Let me just post it uvdn7.github.io/cpp-coro/.
    uvdn7.github.io
    A Mental Model for C++ Coroutine
    C++ coroutine is not a library that is ready to go (e.g. std::vector). It is not even a trait (think of Rust’s Future trait) that library writers or users can implement (or the compiler generates for...
  • @uvdn7
    Lu Pan
    @uvdn7
    Apr 16, 2025
    Guice configuration is like makefile, and injection is like dynamic linking, but all in Java.
  • @uvdn7
    Lu Pan
    @uvdn7
    Jan 7, 2025
    OK I have my answer – I think you should switch.
    @shachaf
    shachaf
    @shachaf
    Jan 5, 2025
    My sister sent me this puzzle. It's so good!
    You are playing the Monty Hall problem. However, you secretly know one of the goats is the former pet of an eccentric billionaire who lost it and is willing to pay an enormous amount for its return, way more than the car is worth. You really want that goat. The host is unaware of this. After you pick your door, as is traditional, the host opens one door, which he knows doesn't have the car. He reveals a goat, which you can tell is the ordinary goat and not the secretly valuable one. The host offers to let you switch doors. Should you?
    read image description
    1
  • @uvdn7
    Lu Pan
    @uvdn7
    Aug 15, 2024
    [new blog post] Access a function's return value in C++ scope guard
    uvdn7.github.io
    Access a function’s return value in C++ scope guard
    It is best to avoid accessing a function’s return value in a scope guard or we need to be really careful about the return value’s lifetime.