The function f(x) takes a string input and modifies it by replacing certain characters with their corresponding uppercase or lowercase versions.

