That's an unusual question. Let's say I have one command with this synopsis:
/usr/bin/wc [-c | -m | -C]
and second command with
head [-number | -n number] [filename]
The question is how many different usage variations(combinations) of these commands can I get? And what are they?
I'm new to UNIX and I'm trying to understand command syntax in general. This question is a part of my "homework" and I'm confused. A friend of mine told me that the answer of a second (head) command is 6. So there should be 6 variations and my guess is that they are
head
head -number
head -n number
head filename
head -number filename
head -n number filename
Is this correct? If so, does a " | " sign between -number and -n number means "or" so that both of them should not be used together? Thanks for your answers.
wc
looks likewc [-c|-m] [-lw] [file...]
. – Kusalananda Feb 20 '17 at 22:46