Citadel|OA|2023 | Coupon Codes | Grouping Options
Citadel · Question · Posted Jul 2023
Question 1 Coupon Codes Several e-commerce websites provide discount coupons as scratch cards to facilitate business. For a coupon code that consists of lowercase English characters, the value of the coupon is calculated as follows: 1. Each lowercase character is mapped to a positive integer, i.e., its corresponding position in the alphabet. So, 'a' is mapped to 1, 'b' to 2, ... and 'z' to 26. 2. The contribution of a character is calculated as (mapped value of the ...
The full answer & interview discussion are available to premium members.
Log in Create a free account