Skip to content

Instantly share code, notes, and snippets.

@kiku1705
Last active April 7, 2021 08:59
Show Gist options
  • Save kiku1705/e663dcf827e1357b892e549d0ea7aa51 to your computer and use it in GitHub Desktop.
Save kiku1705/e663dcf827e1357b892e549d0ea7aa51 to your computer and use it in GitHub Desktop.
def passing_grade(maths,physics,chemistry):
if maths >= 35 and physics >= 35 and chemistry >= 35:
avg_marks = (maths + physics + chemistry) / 3
if avg_marks <= 59:
print("C Grade")
elif avg_marks <= 69:
print("B Grade")
else:
print("A Grade")
else:
print("Fail")
def loop():
x = int(input("Enter a Number: "))
for n in range(1,x):
if n > 100:
break
if n % 10 == 0:
continue
print(n)
def is_prime(num):
for i in (2,num/2):
if num % i == 0:
return False
return True
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment