Bloomberg LP Interview Question for Financial Software Developers
- 0of 0 votes
Given the stats that the highest occurring character in english text is 'e', given a cipher text as input, find out the plain text from it.- souravghosh.btbg March 27, 2011
Given input "bloomberg", the highest occurring characters are 'b' and 'o'. Let's consider 'b'. According to our metric, highest occurring character should be mapped to 'e'.
So 'b' maps to 'e' in plain text.
Now shift all the other characters in the input to the output with the same shift offset.
Output for "bloomberg" = "eorrpehuj".
Also take care for character overflow, i.e. 'z' + 1 should map to 'a' (WRAP AROUND).
ALL CHARACTERS ARE LOWERCASE. Assume.
| Report Duplicate | Flag | PURGE
Bloomberg LP Financial Software Developer Algorithm
Open Chat in New Window