mirror of https://github.com/01-edu/public.git
Delete README.md
This commit is contained in:
parent
85cb73bf6c
commit
089cdf3bfa
|
@ -1,36 +1 @@
|
||||||
## argsort
|
|
||||||
|
|
||||||
### Instructions
|
|
||||||
|
|
||||||
Write a program that checks if an argument is sorted or not, the comparison should be by index of ascii and all printable characters will be used.
|
|
||||||
|
|
||||||
- Your program should return `T` followed by a newline `\n` if the argument is sorted.
|
|
||||||
- Your program should return `F` followed by a newline `\n` if the argument is not sorted.
|
|
||||||
- If the number of arguments is different from 2, do nothing.
|
|
||||||
|
|
||||||
### Usage
|
|
||||||
|
|
||||||
And it's output should be:
|
|
||||||
|
|
||||||
```console
|
|
||||||
$ go run . | cat -e
|
|
||||||
$ go run . a | cat -e
|
|
||||||
T$
|
|
||||||
$ go run . "zA1" | cat -e
|
|
||||||
F$
|
|
||||||
$ go run . " 5ABc" | cat -e
|
|
||||||
T$
|
|
||||||
$ go run . " s" | cat -e
|
|
||||||
T$
|
|
||||||
$ go run . "s " | cat -e
|
|
||||||
F$
|
|
||||||
$ go run . "a b c" | cat -e
|
|
||||||
F$
|
|
||||||
$ go run . " abc" | cat -e
|
|
||||||
T$
|
|
||||||
$ go run . "2?@@^_\`abc" | cat -e
|
|
||||||
T$
|
|
||||||
$ go run . "Hello World" | cat -e
|
|
||||||
F$
|
|
||||||
$ go run . "01Talent" "student" | cat -e
|
|
||||||
```
|
|
||||||
|
|
|
@ -14,15 +14,14 @@
|
||||||
|
|
||||||
- Add a new line (`'\n'`) at the end of the string.
|
- Add a new line (`'\n'`) at the end of the string.
|
||||||
|
|
||||||
|
|
||||||
### Expected function
|
### Expected function
|
||||||
|
|
||||||
```go
|
```go
|
||||||
func FromTo(from int, to int) string {
|
func FromTo(from int, to int) string {
|
||||||
|
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
### Usage
|
### Usage
|
||||||
|
|
||||||
Here is a possible program to test your function :
|
Here is a possible program to test your function :
|
||||||
|
@ -41,6 +40,7 @@ func main() {
|
||||||
fmt.Println(FromTo(100, 10))
|
fmt.Println(FromTo(100, 10))
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
And its output :
|
And its output :
|
||||||
|
|
||||||
```console
|
```console
|
||||||
|
|
Loading…
Reference in New Issue