Help with a simple program!

This is the place for queries that don't fit in any of the other categories.

Help with a simple program!

Postby Ghardt » Wed May 21, 2014 2:52 pm

I have very little experience with python, but I am trying to create a simple program that will:

1) Allow a teacher to input 7 grades
2) Give the average of these grades
3) Calculate a 20% curve on this average (120%)
4) Give the final grade

Could anyone help me out?
Last edited by micseydel on Wed May 21, 2014 8:17 pm, edited 2 times in total.
Reason: Lock.
Ghardt
 
Posts: 1
Joined: Wed May 21, 2014 2:48 pm

Re: Help with a simple program!

Postby metulburr » Wed May 21, 2014 2:53 pm

Please read my signature link new users read this
we will be moving to python-forum.io on October 1 2016
more details here
User avatar
metulburr
 
Posts: 2243
Joined: Thu Feb 07, 2013 4:47 pm
Location: Elmira, NY

Re: Help with a simple program!

Postby Kebap » Wed May 21, 2014 2:58 pm

Ghardt wrote:I I am trying to create a simple program
...
Could anyone help me out?


I don't understand every request, but maybe try something like:

Code: Select all
grades = []
num_grades = 7
for i in range(num_grades):
    new_grade = input("Please type grade:")
    grades.append(new_grade)

print grades
print sum(grades) / float(num_grades)

Then continue from there.
New Users, Read These Hints

Learn: How To Ask Questions The Smart Way
Join the #python-forum IRC channel on irc.freenode.net and chat with uns directly!
Kebap
 
Posts: 689
Joined: Thu Apr 04, 2013 1:17 pm
Location: Germany, Europe

Re: Help with a simple program!

Postby micseydel » Wed May 21, 2014 8:18 pm

Kebap, I'm afraid you've done his homework for him.
Due to the reasons discussed here we will be moving to python-forum.io on October 1, 2016.

This forum will be locked down and no one will be able to post/edit/create threads, etc. here from thereafter. Please create an account at the new site to continue discussion.
User avatar
micseydel
 
Posts: 3000
Joined: Tue Feb 12, 2013 2:18 am
Location: Mountain View, CA

Re: Help with a simple program!

Postby Kebap » Thu May 22, 2014 8:25 am

Maybe.

This is where I get my python exercises these days.
New Users, Read These Hints

Learn: How To Ask Questions The Smart Way
Join the #python-forum IRC channel on irc.freenode.net and chat with uns directly!
Kebap
 
Posts: 689
Joined: Thu Apr 04, 2013 1:17 pm
Location: Germany, Europe


Return to General Coding Help

Who is online

Users browsing this forum: Google Adsense [Bot] and 8 guests