eQ Technologic Interview Question

Replace a given word from a sentence without using any in-built function in Java