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.

25 lines
782 B

## capitalizeprog
### Instructions
Write a program that capitalizes the first letter of each word **and** lowercases the rest of each word of a `string`.
5 years ago
- A word is a sequence of **alphanumerical** characters.
5 years ago
- If there is more than one argument the program should print `Too many arguments`.
5 years ago
- If there is no arguments given the program should print a newline ("`\n`").
### Usage :
```console
student@ubuntu:~/capitalizeprog$ go build
student@ubuntu:~/capitalizeprog$ ./capitalizeprog "Hello! How are you? How+are+things+4you?" | cat -e
Hello! How Are You? How+Are+Things+4you?$
student@ubuntu:~/capitalizeprog$ ./capitalizeprog Hello! How are you? | cat -e
Too many arguments$
student@ubuntu:~/capitalizeprog$ ./capitalizeprog
student@ubuntu:~/capitalizeprog$
```