replace implemented