Browse Source

Changing testing to usage

content-update
MSilva95 3 years ago committed by GitHub
parent
commit
9a30f227f2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 4
      subjects/issorted/README.md

4
subjects/issorted/README.md

@ -2,7 +2,7 @@
### Instructions
Write a function `IsSorted` that returns `true`, if the slice of `int` is sorted, otherwise returns 'false'.
Write a function `IsSorted` that returns `true`, if the slice of `int` is sorted, otherwise returns `false`.
The function passed in the parameter returns a positive `int` if `a` (the first argument) is greater than to `b` (the second argument), it returns `0` if they are equal and it returns a negative `int` otherwise.
@ -16,7 +16,7 @@ func IsSorted(f func(a, b int) int, a []int) bool {
}
```
### Testing
### Usage
Here is a possible program to test your function (without `f`):

Loading…
Cancel
Save