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.
estlop
2155f4b6fc
|
2 years ago | |
---|---|---|
.. | ||
README.md | 2 years ago |
README.md
Instructions
Write a program that checks if a number up to a given number is an odd or even number.
The number will be between 0
and 100
.
- If the number is
odd
then it printsping
as in the example below. - If the number is
even
then it printspong
. - If the number of arguments is invalid then do nothing.
Usage
$ go run . 6 | cat -e
0 ping$
1 pong$
2 ping$
3 pong$
4 ping$
5 pong$
$ go run . | cat -e
$