1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Pepsi [2]
3 years ago
6

Given that note, write a program which tells us the major scale starting at that note, using the pattern above. In the main bloc

k: Use a while loop to continue to ask for notes and then call a function get_scale. In the function get_scale, output the scale using the list. A hint is that you can encode the number of steps as a separate list of offsets. (Since a major scale will always have the same offs
Computers and Technology
1 answer:
White raven [17]3 years ago
5 0

<u>Solution and Explanation:</u>

the_notes = ['C','C#','D','D#','E','F','F#','G','G#','A','A#','B'] #original list

def get_scale(choice): #function to get the major diatonic scale

steps=[1,1,.5,1,1,1,.5] #separate list for steps

size=None

for i in range(0,12): #loop to find out the index of the note entered

if(the_notes[i]==choice):

size =i

break

new_notes=the_notes[size:] + the_notes[:size]

#the above statement rotate the list so that the entered note can become the first note in the new list(i.e new notes)

index =0 #

scale="" #a string to store the major diatonic scale

for i in range(0,7):

scale+=new_notes[index]+" "

if(steps[i]==1):

index = index+2

else:

index=index+1

return scale

#main block

while(1):

choice=input("What scale do you want or Q to quit? ")

if(choice=='Q'):

break

elif(choice in the_notes):

print(get_scale(choice))

else:

print("That is not a note")

You might be interested in
.....is used to save project in Visual basic .net from file menu
Harlamova29_29 [7]

Explanation:

I don't really understand what you're trying to get at, maybe try to abbreviate a little more?

4 0
3 years ago
Who knows my aunt better?
fiasKO [112]

Answer:

yes, yes, 30, November 5

6 0
3 years ago
Read 2 more answers
An_is a sepuence of precise instructions which result in a solution​
Anuta_ua [19.1K]

Answer:

algorithm.

Explanation:

An algorithm can be defined as a standard formula or procedures which comprises of set of finite steps or instructions for solving a problem on a computer. The time complexity is a measure of the amount of time required by an algorithm to run till its completion of the task with respect to the length of the input.

Furthermore, the processing symbols and their functions used in developing an algorithm are oval (start or stop), diamond (decision-making), circle (on-page connector), parallelogram (input and output), rectangle (calculation), arrow (flow or direction) and pentagon (off-page connector).

Some of the characteristics of an algorithm include the following;

I. An algorithm can be written using pseudocode. A pseudocode refers to the description of the steps contained in an algorithm using a plain or natural language.

II. An algorithm can be visualized using flowcharts. A flowchart can be defined as a graphical representation of an algorithm for a process or workflow.

In conclusion, an algorithm is a sequence of precise instructions which result in a solution​ for solving problems using a computer system.

5 0
3 years ago
Memory is a _____________ that includes the organization and shaping of information by processing, storage, and retrieval of inf
vaieri [72.5K]

Answer:

A. <em>Encoding Process </em>

Explanation:

Memory is an <em>encoding process </em>that includes the organization and shaping of information by processing, storage, and retrieval of information.

There are two types of memory in computing, <em>RAM </em>and <em>ROM</em>. <em>RAM </em>stands for <em>Random Access Memory</em>. It I the core memory of the computer and it is especially faster regarding reading and writing process. As an analogy, RAM memory is like the “<em>Short-term</em>” memory of the computer. <em>ROM </em>stands for <em>Read-Only Memory</em>, this is the type of memory in charge of permanently storing data in the computer. It contains the necessary information to run the computer. As an analogy, <em>ROM </em>memory is like the “<em>long-term</em>” memory of the computer.

3 0
3 years ago
When using a calculator, be sure you press ____ first?
sertanlavr [38]
The answer to this question is: CE
Calculator will memorize the input that you made from previous calculation until you press the = button.
CE stands for clear data, which means that by pressing this, you will eliminate the calculation from previous effort and start the new calculation on a blank state
4 0
3 years ago
Read 2 more answers
Other questions:
  • Ned and Mary Ann are saving their files to a CD. When prompted, Ned will click on Burn file to disk, indicate the recording spee
    15·1 answer
  • What will happen when a user attempts to login to salesforce from an ip address that is outside the login ip range on the user's
    15·1 answer
  • What is the purpose of the making of Nintendo Switch?
    10·2 answers
  • Can include the 5-tuple information, which is the source and destination ip addresses, source and destination ports, protocols i
    9·1 answer
  • Explain the<br>4 ways<br><br>ways of arranging icons.<br><br>​
    6·1 answer
  • Anybody wanna be friends?
    10·2 answers
  • What is command is used to improve the vocabulary and in which tab is it found​
    14·1 answer
  • Which key combination should you use
    9·2 answers
  • I dont know how to put the negative sigh on my computer
    5·2 answers
  • Question 1 Which portion of the PuTTY package allows you to perform file transfers using the SCP (Secure Copy) protocol?
    12·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!