Lumber Jack and Grammar

Lumber Jack loves both grammar and popular TV shows. Lately, he has developed an obsession for finding and correcting grammatical errors in his subtitles.

More precisely, he has come up with two rules which define a great subtitle:

  • Periods and dashes are confusing. Let them be no more.
  • Commas must be preceded by an extra space, for the sake of symmetry.

Your task is to correct Lumber Jack's subtitle (that is, remove all periods and dashes and add a space before each comma, including commas that are already preceded by a space).


The first line of the input contains a string representing the subtitle.


The first line of the output should cointain the input subtitle, with all mistakes corrected.


  • 1 ≤ the length of the subtitle ≤ 100


"Bulaneala asta n-ar trebui sa intre, parerea mea." - Cosmin"Bulaneala asta nar trebui sa intre , parerea mea"  Cosmin

Sponsors Gold