Company: Amazon_july
Difficulty: medium
Security Code Transformation Problem Description Developers at Amazon are creating a single sign-on application for the web apps in AWS. In one of its modules, a security code is in the form of a binary string that changes every minute. The characters at a pair of indices i and i+1 are swapped such that the resulting code is the lexicographically maximum binary string that can be achieved in this step. If it is not possible to make the code lexicographically greater, then the code does not change. String x is lexicographically greater than string y if either y is a prefix of x (and x ≠ y ), or there any i exists such that (0 ≤ i x |, | y |)), that x i i , and for any j (0 ≤ j i ) x j = y j . Here, | a | denotes the length of the string a . Given the string initialCode , and an integer minutesElapsed , find the security code after minutesElapsed minutes. Complete the function getCodeAtTime in the editor below. getCodeAtTime has the following parameter: string initialCode : the initial s