ByteDance Interview Question

Basic test on the understanding of algorithms