Write a code segment that reads a table of frequencies into the scale array declared in Exercise 13 from a file called frequencies.dat. The frequency values are arranged one per line on the file.
REF PRB:
A piano is tuned in a scale that is slightly unequal (called a “well-tempered scale”), rather than a perfectly scientific scale in which each note sounds at twice the frequency of the same note an octave below (called a “just scale”). For this reason, we can’t simply calculate the frequency of a note, but rather must keep it in a table. Declare a two-dimensional array (scale) to hold the frequencies of the well-tempered scale. A frequency is represented by a float value. The row dimension is indexed by an int value representing the octave (there are 8 octaves, numbered 0 through 7), and the column dimension is indexed by an enumeration type (Notes) consisting of the names of the notes. When you write the declaration of the enumeration type, use only sharps (no flats). The note names of an octave are C, CSHARP, D, DSHARP, E, F, FSHARP, G, GSHARP, A, ASHARP, and B, in that order.
We need at least 10 more requests to produce the solution.
0 / 10 have requested this problem solution
The more requests, the faster the answer.