public static void Main()
var res = GetResult("codeforces");
public static string GetResult(string inputString)
var input = inputString.ToCharArray();
bool anythingExceptA = false;
for (int i = 0; i < input.Length; i++)
if (input[i] == 'a' && !anythingExceptA)
else if (input[i] == 'a' && anythingExceptA)
return new string(input);
input[i] = (char)(input[i] - 1);
input[input.Length - 1] = 'z';
return new string(input);