500+ quant interview questions for Jane Street, Citadel, Two Sigma, DE Shaw, and other top quantitative finance firms.
Statistical analysis and quantitative modeling problems
Trading MCQs, probability brainteasers, and market scenarios
Practice quant interview questions on MyntBit - the all-in-one quant learning platform. Free questions available for C++ coding, Python problems, probability brainteasers, and trading MCQs.
Difficulty: Easy
Category: low_latency
Practice quant interview questions from top firms including Jane Street, Citadel, Two Sigma, DE Shaw, and other leading quantitative finance companies.
Topics: clock-gettime, timespec, rdtsc, low_latency, timing, monotonic
High-frequency trading systems require nanosecond-precision timestamps to measure latency for market events. The clock_gettime function provides timestamps as a struct timespec, containing separate seconds and nanoseconds fields. Correctly calculating the elapsed time between two such timestamps requires careful mixed-unit arithmetic to avoid overflow or truncation errors. Task Implement the function elapsed_ns(long t1_sec, long t1_ns, long t2_sec, long t2_ns) to compute the total elapsed time
Practice this easy developer interview question on Myntbit - the all-in-one quant learning platform with 1000+ quant interview questions for Jane Street, Citadel, Two Sigma, and other top quantitative finance firms.