ا ر
Python
$# أ:
fromdatetime import
dob=int(input("Enter the date of
:" ))birth
today=datetime.today)(
year=today.year
age=int(year)-int(dob)
print ("you age is :", age)
C++
$# أ:
#include <iostream>
#include <string>
int main()
{ std::string name;
std::cout << "What is your name? ";
getline (std::cin, name); std::cout <<
"Hello, " << name << "!n";
}
درب ا/DAOWD.A.ZAILAYرس٢٠١٩
6.
ا ر
Python
$# أ:
S= 5
if S == 5:
print('S is equal 5')
else:
print('S is not equal 5')
S is equal 5
C++
$# أ:
#include <iostream>
using namespace std;
int main()
{
int i, j;
for(i=1; i<=5; i++)
{
for(j=1; j<=3; j++)
cout << " * ";
cout << "n";
} درب ا/DAOWD.A.ZAILAYرس٢٠١٩