def replace_printable(s, printables, wild=" "):
    """
    If the character in s is not in printables, replaces by wild.
    """
    new_s = ""

    for i in s: 
        new_s += i if i in printables else wild
        
    return new_s