تمرین برنامه نویسی؛ با کدبزن!

منبع جامع سوالات و تمرینات برنامه نویسی

13
+1
+1
+1

تفاضل سن پدر و پسر

Amirhn آسان 55/ دانلود 2083 بازدید

برنامه ای بنویس که سن پدر و پسری را از ورودی دریافت کند و تفاضل (تفریق) آنها را در خروجی چاپ کند

57 جواب

نمیتونم این تمرین رو حل کنم!
1
+1
# تفاضل سن پدر و پسر
pedar = input("pedar:")
pesar = input('pesar:')
a = int(pedar)
b = int(pesar)
print(a-b)
کاربر 462 دانلود Python
1
+1
pedar = int(input("sene pedar ra vared konid : "))
pesar = int(input("sene pesar ra vared konid : "))
print("tafazol sen :",pedar-pesar)
Amirhosseint دانلود Python
0
father = int(input('please enter your age : '))
boy = int(input('please enter your boy age : '))
result = (father - boy)
print(result)
Naaji دانلود Python
0
a= input("sen pedar?")
b= input("sen pesar?")
a=int(a)
b=int(b)
print(a - b , "ekhtelaf") 
کاربر 96 دانلود Python
0
Father=input("please give your age?")
Sun=input ("please give your age?")
Father=int(father)
Sun=int(sun)
Print(father - sun)
4t3in دانلود Python
0
age_father = input("plase your age dad>>> ")
age_father =int(age_father)
age_child = input("plase your age child>>> ")
age_child =int(age_child)
result = age_father - age_child
print(result)
Moje4777 دانلود Python
0
father=int(input("enter father age:"))
boy=int(input("enter boy age:"))
output=father-boy
print(output)
Amirowich دانلود Python
0
1 = Input ( dad )
2 = Input ( son )
3 = print ( 1 ) - ( 2 )
Sina123 دانلود Python
0
pedar= int(input(" age :"))
pesar= int( input('age  :'))


b = pedar - pesar
print(b)

کاربر 308 دانلود Python
0
# age1 is for father and age2 is for sun
age1 = int(input(" what is father age? "))
age2 = int(input(" what is sun age? "))
print( age1 - age2 )
کاربر 430 دانلود Python
<< صفحه قبل 1 2 3 6 صفحه بعد >>

ارسال جواب

// کداتو توی این بخش بنویس
// فرقی نمیکنه چه زبان برنامه نویسی باشه، همرو پشتیبانی میکنیم :)
// البته قبلش این سه خط رو پاک کن
                    
  • لطفا جواب های تکراری ارسال نکن
  • قبل از ارسال، جوابت رو داخل یک کد ادیتور مثل vscode بنویس و بعد اینجا Paste کن
  • جواب های ارسالی، پس از بررسی کوتاهی، ویرایش میشن و در سایت نمایش داده میشن
  • ارسال جواب حق مادی یا معنوی برای ارسال کننده ایجاد نمیکند و تمام حقوق برای سایت کدبزن محفوظ است

تمرینات مرتبط

تشخیص با استفاده از هوش مصنوعی
×
×
بستن