For this exercise you will need to know the following new commands:
UNIX Commands | Humdrum Commands |
---|---|
grep -n; grep -v | ditto |
more +num | |
Change directories to /var/opt/Humdrum/Scores/ and answer the following questions. For each question, keep a record of both the answer, and the command(s) used to find your answer.
COMMAND: deg -a [file] | ditto -s = | grep '6-.*4+'
ANSWER: Opus 50, No. 5 (2nd mov.) and Opus 64, No. 5 (2nd mov.)
COMMAND: deg -a h50n5b | ditto -s = | grep -n '6-.*4+'
more +70 h50n5b
more +108 h50n5b
more +312 h50n5b
more +435 h50n5b
more +518 h50n5b
more +520 h50n5b
ANSWER: measures 7, 12, 28, 38, 43
COMMAND: deg -a [file] | ditto -s = | grep '6-.*4+' | grep '2'
COMMAND: deg -a [file] | ditto -s = | grep '6-.*4+' | grep -v '[23]'
COMMAND(S): deg -a [file] | ditto -s = | grep '4' | grep '6' | grep '1' | sort | uniq -c | sort -n
ANSWER: 32 instances of: 4 6 1 6