#C10878. Taco String Filter

    ID: 40131 Type: Default 1000ms 256MiB

Taco String Filter

Taco String Filter

You are given a string S and a second string representing a set of characters to remove. Your task is to filter out all characters from S that appear in the removal set. In other words, if a character c belongs to the set \( R \) (i.e. \( c \in R \)), then it should not appear in the output. Otherwise, it should be included.

The input is provided via standard input (stdin). The first line contains the original string \( S \). The second line contains the characters to remove (which represents the set \( R \)).

For example, given the input:

hello world
lo

The output should be:

he wrd

Note that removal is case-sensitive.

inputFormat

The input is read from standard input (stdin) and consists of two lines:

  • The first line is the string \( S \) (which may contain spaces and other characters).
  • The second line is a string whose characters represent the set \( R \) of characters that should be removed from \( S \). If this line is empty, no characters are removed.

outputFormat

The output, printed to standard output (stdout), is the filtered string obtained by removing all characters from \( S \) that appear in \( R \).

## sample
hello world
lo
he wrd