Implement encryption and constant-time random set | Axon Interview Question