Coursera: Assignment 3.3 Python for everybody assignment solution//#Python assignment solution

preview_player
Показать описание
# Coursera :-
#Programing for everybody
# Python

CHAPTER :-
QUIZ
QUESTION WITH ANSWER
👇Chapter :- 1 Quiz 👇
👇Chapter :- 2 Quiz 👇
👇Chapter :- 3Quiz 👇

👇Chapter :- 4 Quiz 👇

👇👇Assignment :- 2.2👇👇

👇👇Assignment :- 2.3👇👇

👇👇Assignment :- 3.2👇👇

👇👇Assignment :- 3.3👇👇

👇👇Assignment :- 4.6👇👇

______________________________________
👇👇Programing run code 👇👇

___________________________________________
Python is a general purpose and high level programming language. You can use Python for developing desktop GUI applications, websites and web applications. Also, Python, as a high level programming language, allows you to focus on core functionality of the application by taking care of common programming tasks
____________________________________________
DISCLAIMER :-
This vedio is for educational purposes only. Copyright disclaimer under section 107 of the copyright Act 1976, allowance is made for "fair use" For purpose such as criticism, comment, news reporting, teaching, scholarships & research . Fair use is permitted by copyright statue that might otherwise me infringing non-profit , education or professional, use tips the balance in favor of fair use.

____________________________________________

_____________
PLEASE LIKE,SHARE & SUBSCRIBE 😍
THANKING YOU 😘
Рекомендации по теме
Комментарии
Автор

Updated with simple commands to include
- skipping error for non floats,
- not quitting but going to start when non float of out of range numbers entered,
- asking if you want to calculate another grade or quit.

def grade_calculator():
while True:
score = input("Please Enter Score between 0.0 and 1.0: ")
try:
if float(score) > 1 or float(score) < 0:
print('out of range')
continue
elif float(score) < .6:
grade = 'F'
break
elif .7 > float(score) >= .6:
grade = 'D'
break
elif .8 > float(score) >= .7:
grade = 'C'
break
elif .9 > float(score) >= .8:
grade = 'B'
break
else:
grade = 'A'
break
except:
print('please enter a valid floating number')
continue
print(grade)


grade_calculator()

while True:
repeating = input('would you like to enter another score (y or n) ?')
if repeating != 'y' and repeating != "n":
print("please enter y or n")
continue
elif repeating == "n":
print('program ended')
quit()
else:
grade_calculator()

cankrkurdozdemir
Автор

Thnxx a lot bro.. After lot of trials this code finally work without any errors..

darshanawakalkar
Автор

inp = input("Choose a score between 0.0 and 1.0")

score = float(inp)

 

if score >= 0.0 and score < 0.6:

   print('F')  

 

 

elif score >= 0.6 and score < 0.7:

   print ('D')  

 

elif score >= 0.7 and score < 0.8:

   print ('C')  

 

elif score >= 0.8 and score < 0.9:

   print ('B')  

 

elif score >= 0.9 and score <= 1.0:

2 / 2

   print( 'A')  

 

else:

   print('Error: input not within range')

avuladurgaprasad
Автор

Guys, if you're getting " Check code " even if the syntax and the program is right.. it's because the desired output is 'B' grade.. so during input if you enter ' 0.8 ' it will run successfully

rishabhparmar
join shbcf.ru