Average 2 pcs
Write a program that receives two users and prints the mean on output
Write a program that receives two users and prints the mean on output
let msg = 'error' alert(msg)This answer is only visible to premium members
This answer is only visible to premium members
let msg = 'error' alert(msg)This answer is only visible to premium members
This answer is only visible to premium members
let msg = 'error' alert(msg)This answer is only visible to premium members
This answer is only visible to premium members
def calculate_average(): # Receive two numbers from the user num1 = float(input("لطفاً عدد اول را وارد کنید: ")) num2 = float(input("لطفاً عدد دوم را وارد کنید: ")) # Calculate the mean average = (num1 + num2) / 2 # Average printing print(f"میانگین دو عدد {num1} و {num2} برابر است با: {average}") # Implementation of the function calculate_average()
class Math: def __init__(self,num1,num2): self.num1=num1 self.num2=num2 def Way(self): return (self.num1+self.num2)/2 num1=int(input("enrer your number1:")) num2=int(input("enter your number2:")) obj=Math(num1,num2) print(obj.Way())
def cp(a,c): global s s = (a + c)/2 print(s) a = int(input("number1:")) c = int(input("number2:")) cp(a,c)
def average(num1,num2): ave = (num1 + num2)/2 return ave a = float(input("number 1: ")) b = float(input("number 2: ")) print("average is: ",average(a,b))
a=int(input( 'num:')) b=int(input( 'num:')) print(a+b)
def miyangin(n,m): c = (m + n) / 2 return c print(miyangin(m=int(input("enter your m:")),n=int(input("enter your n:"))))
a = float(input("number 1 :")) b = float(input("number 2 :")) sum= a + b AVG= sum / 2 print("miangin:" , AVG)
Submitting answers is currently unavailable.
Write a program that receives 2 numbers as the interval, in which the interval of all the 5 existing numbers. For example, in the interval of 1 to 20 the number 2 times the number 5 repeated (5 and 15)
Design the database of a restaurant and write a query about making tables and keys. Tips: In this restaurant we want to have a list of foods, orders and customers in the system
Write a program that receives the age of father and son from the input and prints them (subtraction) in the output
Write a program that receives the user's username and password and checks whether the username and password entered are correct? Username - Passwordamirhossein - 12345hooshang - 009922 ...
Write a program that receives a store product listing including name and product price and will continue until the amount of empty value for the product name is entered; Then the product name is displayed as a list ...
Write a program that receives 2 users and calculates the Fibonacci series (between those two) and prints in the output
Define a class of User that has a username, email and password and the following methods. Print: Print username and email in the output IS_Gmail: Check whether the user's email is Gmail and ...
برای استفاده از این بخش باید وارد حساب کاربریت بشی
ورود/ثبت نام If you don’t understand the exercise or can’t solve it for any reason, that’s completely
normal—don’t worry 😊
Try checking out easier exercises and reviewing different answers
submitted by others. Gradually, you can move on to more challenging exercises. Also, your answer
might be correct even if it’s different from others.