hiho#1082 but the marsh-leaping fish has long seen everything.

Source: Internet
Author: User

#1082: However, the marsh-jumping fish has long seen through all time limits:1000msSingle Point time limit:1000msMemory Limit:256MB
Describe


FJXMLHX is being brushed by a swamp fish every day, so he's eagerly finding you. You want to write a program that masks all the sentences in the Marsh Jump Fish ("marshtomp", not case sensitive). In order to make the sentence not lack of ingredients, unified replaced by "FJXMLHX".

Input

The input includes multiple lines.

Each line is a string with a length of not more than 200.

The end of a line has no relation to the beginning of the next line.

Output

The output contains multiple lines, as the input follows the result of the transformation in the description.

Sample input
The Marshtomp have seen it all before.marshtomp are beaten by fjxmlhx! Amarshtompb
Sample output
The FJXMLHX have seen it all before.fjxmlhx are beaten by fjxmlhx! Afjxmlhxb
Why do I have to do water problems again haha

#include <stdio.h> #include <string.h>int main () {char str[205];while (gets (str)!=null) {int Len=strlen (str ); for (int i=0;i<len;i++) {if (I+8>=len) break;if ((str[i]== ' m ' | | | str[i]== ' M ') && (str[i+1]== ' A ' | | str[i+1]== ' A ') && (str[i+2]== ' R ' | | str[i+2]== ' R ') && (str[i+3]== ' s ' | | str[i+3]== ' S ') && (str[i+4]== ' h ' | | str[i+4]== ' H ') && (str[i+5]== ' t ' | | str[i+5]== ' T ') && (str[i+6]== ' O ' | | str[i+6]== ' O ' && (str[i+7]== ' m ' | | str[i+7]== ' M ') && (str[i+8]== ' P ' | | str[i+8]== ' P ')) {str[i]= ' F '; str[i+1]= ' j '; str[i+2]= ' x '; str[i+3]= ' m '; str[i+4]= ' l '; str[i+5]= ' h '; str[i+6]= ' x '; str[i +7]= ' * '; str[i+8]= ' * ';}} for (int i=0;i<len;i++) {if (str[i]!= ' * ') printf ("%c", Str[i]);} printf ("\ n");}}



hiho#1082 but the marsh-leaping fish has long seen everything.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.