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
Lemur [1.5K]
2 years ago
8

Need Help! Asap 7.5 code practice (Edhesive)

Computers and Technology
2 answers:
hram777 [196]2 years ago
7 0

Answer:

def GPAcalc(g, w):

   if g == "a" or g == "A":

       return 4 + w

   elif g == "B" or g == "b":

       return 3 + w

   elif g == "C" or g == "c":

       return 2 + w

   elif g == "D" or g == "d":

       return 1 + w

   elif g == "F" or g == "f":

       return 0 + w

   else:

       return "Invalid"

       

def GPAAV(S, C):

   return S/C

   

Sum = 0

Classes = int(input("How many Classes are you taking? "))

for i in range(0, Classes):

   Grade = (input("Enter your Letter Grade: "))

   Weight = int(input("Is it weighted? (1= yes) "))

   gpa = GPAcalc(Grade, Weight)

   print("Your GPA score is: " + str(gpa))

   Sum = Sum + gpa

print("Your weighted GPA is a " + str(GPAAV(Sum, Classes)) + ".")

Explanation:

This one should work, let me know in the comments.

erma4kov [3.2K]2 years ago
5 0

Answer:

Make main function

def main():

Make some constants for the grades

A = 5.0 or 4.0

B = 4.0 or 3.0

C = 3.0 or 2.0

D = 2.0 or 1.0

F = 1.0 or 0.0

In the main function call the function you made and make sure to use those constants for help

also don't forget to call your main function or nothing will work

Explanation:

Making the main function is good programming practice for your future

Making the constants is also helpful to your programming.

Now how it works you call the function you wrote to calculate the grade.

I don't know how helpful this was this is one of my first answers. I am `also answering how I would do it

You might be interested in
What type of windows network model allows all the participants to be represented equally on the network with no single computer
noname [10]
The workgroup as a type of windows network model allows all the participants to be represented equally on the network with no single computer having authority or control over another. The workgroup is peer-to-peer local area network. 
Members of this network group can share files, printers, Internet connection.<span> and other local network resources.</span>
4 0
3 years ago
Which type of text may be formatted to print at the bottom of every page?
Tatiana [17]
The answer is header.
3 0
2 years ago
WHO WANTS TO PLAY AMONG US
Elza [17]

Answer:

Explanation:

ME

8 0
3 years ago
Read 2 more answers
What is the reason that friction is present in surface to surface contact?
Andrej [43]
One surface is larger than the other surface
3 0
2 years ago
Which of the following is not an example of a technological aid?
emmainna [20.7K]
I think the correct answer among the choices given is option A. Manipulative aids are not technological aids. It refers to items that is used to support hands-on learning like markers, toothpick or coins. Technological aids, on the other hand, are things which makes use of the new technology present like slideshows, DVD's, audioclips and projectors.
6 0
2 years ago
Other questions:
  • What type of rain happens when cold air meets warm air
    14·1 answer
  • What is a flash player?
    9·2 answers
  • What options of the hierarchical star topology within the ANSI/TIA-568-C allow the ability to move the workgroup switches closer
    7·1 answer
  • The command button to protect a document is part of the​.
    10·1 answer
  • Finish the statement below to correctly describe the Defense Enrollment Eligibility Reporting System (DEERS). DEERS is a central
    6·1 answer
  • Any recommendations for anime series on netflix?
    14·1 answer
  • Write a program that:
    13·1 answer
  • What is the most commonly used tab in the Filter dialog box?
    9·2 answers
  • Using pointers and shared memory for IPC, what would you need to add to your code to ensure data integrity?
    15·1 answer
  • What is pollution?
    14·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!