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]
3 years ago
8

Need Help! Asap 7.5 code practice (Edhesive)

Computers and Technology
2 answers:
hram777 [196]3 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]3 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
Universal Containers wants line items to be organized into pre-defined groups on the output document. The name of these pre-defi
devlian [24]

Answer:

Set the Group field on the Line Items type of Template Content record.

Set the New Quote Group field on each Product record with the associated group name.

Explanation:

The two array that can be implemented are:

  • Set the Group field on the Line Items type of Template Content record.
  • Set the New Quote Group field on each Product record with the associated group name.
5 0
3 years ago
How to do a row of circles on python , with the commands , picture is with it .
kotykmax [81]

Answer:

o.o

Explanation:

5 0
3 years ago
It would be at least two decades before some of the technologies he demonstrated saw widespread use, but all of them are used by
Phoenix [80]

Answer:

all of the above

Explanation:

7 0
3 years ago
A non technical kind of cyber intrusion that relies heavily on human interaction and often involve tricking people into breaking
lana66690 [7]
Social Engineering.

---------------------------
4 0
3 years ago
A(n) _____ is a common output device for hard copy.
Sidana [21]
The answer is d it is d it is d I think I think, I’m not sure though
8 0
3 years ago
Other questions:
  • Which type babshshshhsshshhshshshhshs
    13·1 answer
  • What Linux services can pose a problem when attempting to reach remote host on a network?
    5·2 answers
  • The concept of _________________ comes from the acknowledgment that data changes form and often gets copied, moved, and stored i
    7·1 answer
  • In a study on software license infringement, those from United States were significantly more permissive than those from the Net
    15·1 answer
  • Java: which expression is evaluated first
    13·1 answer
  • Write a function process_spec that takes a dictionary (cmap), a list (spec) and a Boolean variable (Button A) as arguments and r
    10·1 answer
  • An information system is the set of steps that needs to be followed to ensure that software development proceeds in an orderly f
    13·1 answer
  • Cottonisagoodreflectorofsound​
    6·2 answers
  • Help me asap ill give brainliest
    8·1 answer
  • You discover that the lecturers will be using the laptops for online and video lecturing, and you see the need to upgrade the RA
    5·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!