This can be done with something like (pseudocode):
Code:
in = input char[]
out = new char[] with the same size as in
for each character in 'in' {
    if character!='&' {
        append character to out;
    }
}