mirror of https://github.com/01-edu/public.git
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
24 lines
925 B
24 lines
925 B
5 years ago
|
## wdmatch
|
||
6 years ago
|
|
||
5 years ago
|
### Instructions
|
||
6 years ago
|
|
||
5 years ago
|
Write a program that takes two `string` and checks whether it is possible to write the first `string` with characters from the second `string`, while respecting the order in which these characters appear in the second `string`.
|
||
6 years ago
|
|
||
5 years ago
|
If it is possible, the program displays the `string` followed by a newline (`'\n'`), otherwise it simply displays nothing.
|
||
6 years ago
|
|
||
5 years ago
|
If the number of arguments is different from 2, the program displays nothing.
|
||
6 years ago
|
|
||
5 years ago
|
### Usage
|
||
6 years ago
|
|
||
|
```console
|
||
5 years ago
|
student@ubuntu:~/[[ROOT]]/test$ go build
|
||
5 years ago
|
student@ubuntu:~/[[ROOT]]/test$ ./test faya fgvvfdxcacpolhyghbreda
|
||
6 years ago
|
faya
|
||
5 years ago
|
student@ubuntu:~/[[ROOT]]/test$ ./test faya fgvvfdxcacpolhyghbred
|
||
|
student@ubuntu:~/[[ROOT]]/test$ ./test error rrerrrfiiljdfxjyuifrrvcoojh
|
||
5 years ago
|
student@ubuntu:~/[[ROOT]]/test$ ./test "quarante deux" "qfqfsudf arzgsayns tsregfdgs sjytdekuoixq "
|
||
6 years ago
|
quarante deux
|
||
5 years ago
|
student@ubuntu:~/[[ROOT]]/test$ ./test
|
||
|
student@ubuntu:~/[[ROOT]]/test$
|
||
6 years ago
|
```
|