Wild Card
Very easy
Execution time limit is 1 second
Runtime memory usage limit is 64 megabytes
String file contains the file name. You must rename it to match the string pattern that can contain the joker symbol ‘?’ (any one symbol) using the minimal number of moves. A move is defined as adding a character, deleting a character, or modifying a character from the filename.
Input
Each line contains two strings file and pattern of length no more than 50. Each character in file is a lowercase letter ('a' - 'z'). Each character in pattern is a lowercase letter ('a' - 'z') or '?'.
Output
For each pair of strings print in a separate line the minimal number of moves that transform file to pattern.
Examples
Input #1
Answer #1
Submissions 356
Acceptance rate 50%