M idpath

MidPath hiring

You need to edit the program given below. Please do not use any kind of GPT tool.

If the character is a digit, leave it unchanged. If the position of the character is a multiple of 3 then rotate the character by 5. If the position of the character is a multiple of 5, rotate it by 9. However, if the character's position is a multiple of both 3 and 5, rotate it by 3. If it is a multiple of 7, rotate by 8. If none of these conditions are satisfied, rotate the character by 2.

To rotate by 'k' by 4 we need to find the character 4 places before 'k' in alphabetical order which is 'g'. Consider only lowercase a-z characters and assume that they are cyclic in nature.


When you have written your program, click on 'Run program' button and the link text below will change. If your program is correct, clicking on it will take you to the next step in the hiring process, if it is wrong, you will reach a 404 page.

/aklajewlfjk

    
    

Midpath Software Pvt Ltd © 2025