Company: Nike_26nov
Difficulty: medium
The Digital Vault - Unlock the Secret Code The Digital Vault - Unlock the Secret Code Problem Description You are a master hacker trying to unlock an ancient digital vault. The vault has a peculiar security system that only accepts specific unlock codes based on three mysterious rules discovered in old manuscripts. The vault's digital display shows only two digits that are functional (all other digit keys are broken). You must generate an unlock code using ONLY these two working digits. The vault also has a "key number" K inscribed on it. Your task is to find the SMALLEST possible integer code that satisfies ALL of these conditions: The code must be GREATER than the key number K. The code must be PERFECTLY DIVISIBLE by K (i.e., code % K == 0 ). The code can ONLY contain the two working digits ( digit1 and/or digit2 ). If no such code exists within the 32-bit signed integer limit (2 31 - 1), you should return -1. Examples Example 1: Input: K = 15, digit1 = 1, digit2 = 5 Output: 555 Expl