Epic Interview Question

Substring replacing.