Cody

Problem 2500. Text Processing - New

Derived from problem 2440.

A string containing several sentences are given as input. If any sentence contains the word 'great' more than twice, replace every second 'great' of that sentence with the word 'awesome'.

Example:

Input = 'Sheldon, Penny, Leonard and Raj are great and great and great and great receptively. Wolowitz is just a great jerk';

Output = 'Sheldon, Penny, Leonard and Raj are great and awesome and great and awesome receptively. Wolowitz is just a great jerk';

Solution Stats

29.03% Correct | 70.97% Incorrect
Last solution submitted on Jan 09, 2019

Problem Comments

Recent Solvers10

Suggested Problems

More from this Author45

Tags