4 votes
Accepted

Fast OrderBook Implementation

Adding to pacmaninbw's review: There's a hole in struct Order There's a hole between price and ...
G. Sliepen's user avatar
  • 55.5k
4 votes

Fast OrderBook Implementation

General Observations The general impression of the code is that this is a fast and dirty implementation. Take the time you need to design and implement a proper solution. Some things that the code is ...
pacmaninbw's user avatar
  • 23.8k
3 votes

OrderBook Implementation - Follow up

There are no include guards for the header. using orderid_t = uint32_t; uint32_t is not defined. I recommend ...
Toby Speight's user avatar
3 votes

Design decisions for an efficient OrderBook

I have to admit that I struggle to follow this. The code seems quite jumbled, rather than well-organised and clear. The biggest issue I have is with representing everything as arrays of strings, ...
Toby Speight's user avatar
2 votes

Fast OrderBook Implementation - Follow Up

There's still a hole in struct Order You moved short price to the end of the struct, but ...
G. Sliepen's user avatar
  • 55.5k
2 votes

Fast OrderBook Implementation - Follow Up

General Observations The code is still missing the #include <sstream> directive in main.cpp and does not compile for me without it. The file ...
pacmaninbw's user avatar
  • 23.8k
2 votes

Simple credit card validation with Luhn's Algorithm

Follow the specs Credit card numbering is a well-defined system, standardized in ISO/IEC 7812. While accessing the standard text is expensive, the outline of its contents is well documented and ...
gazoh's user avatar
  • 3,249
2 votes

Design decisions for an efficient OrderBook

Create a type for currency Instead of passing currency around as a long long or double, I strongly suggest you create a new type ...
G. Sliepen's user avatar
  • 55.5k
2 votes

edgar: Programmatic access to SEC's Edgar API in Python / via command-line

Optional from typing import ..., Optional Type annotations have been evolving. In recently authored source code, prefer e.g. ...
J_H's user avatar
  • 25k
1 vote

edgar: Programmatic access to SEC's Edgar API in Python / via command-line

If you need to throttle access against rate-limited resources or implement retry on failure you can use urllib3 in conjunction with requests like this: Source: Example: Automatic Retries ...
Kate's user avatar
  • 6,510
1 vote

edgar: Programmatic access to SEC's Edgar API in Python / via command-line

Don't inherit from object in Python 3. Limiter has been designed at the incorrect level of instantiation. Its ...
Reinderien's user avatar
1 vote
Accepted

Aggregate transactions in slips

How can I improve ... performance and scalability? use an appropriate data structure The inner loop makes a O(N) linear scan over the array of all transactions, for each slip transaction. There are ...
J_H's user avatar
  • 25k

Only top scored, non community-wiki answers of a minimum length are eligible