موقع طلبة جامعة البحرين

يمكنك تصفح الموقع كزائر ولكن ندعوك لتسجيل عضوية خاصة بك لتحصل على كافة الصلاحيات مثل تنزيل ملفات المكتبة وقراءة تعليقات هيئة التدريس وغيرها. يمكنك الحصول على عضوية مجانية بالضغط على زر تسجيل. إذا قمت بالتسجيل مسبقا فيمكنك الضغط على زر دخول.

تسجيل دخول
  • قسم المكتبة الجامعية مغلق مؤقتا بعد الاستهداف التي تعرضت له بعض خدمات أمازون في البحرين، جاري استرجاع الملفات ونقلها إلى سيرفرات جديدة وسيتم بعدها اعادة افتتاح المكتبة

ITCS112 - ITCS104 - ITCS102 للفصل الصيفي 2014 - 2015

write function sort that use bubble sort the message according to their size:
void buublesort Email (Email mailBox[], int size);

write function search th that returns true if (T0 person) equals yo "To" in mail box:
bool searchTo(Email mailBox[],int size,string Toperson);

ممكن تشرحولي كيف الحل؟؟؟
 
شخبااااركممم شعبناا :RpS_love: :bleh:

:RpS_love:
  1. Set and get functions for all data members. The setBloodgroup function should check the validity of the blood group before assigning it to bloodGroup by calling the function Is_BloodBroup_Valid described below.

هذا السؤال ضمن السؤال السابق الي خلوه الاعضاء .. بس بغيت اعرف هم يبون فنكشن set & get بروحها تالي فنكشن Is_BloodBroup_Valid setBloodgroup بعد وحدة غير ؟؟ يعني يصيرون دلين 3 فنكشنز او set بس وحدة ؟؟ ويصير المجموع 2 ! :nosweat:
 
يبون فنكشن set & get
و فنكشن تجيك لين فاليد ولا لا عشان بعدين تستدعينها
 
طيييب مشكووورة خية
 
Assignment#5
Create a class called BloodDonor that maintains information about blood donors in a blood bank having the following data members:​


  1. [*=left]IdNumber, // long int
    [*=left]name, //Name of donor
    [*=left]bloodGroup//String
    [*=left]home_Phone//String
    [*=left]mobile_Phone//String
    [*=left]address // struct Address that holds int house number, int road number, int block
    number, string city, and string country
It will also have the following member functions:​


  1. [*=left]Constructor function with default values IdNumber = 0, name = "", bloodGroup = "",
    home_Phone="", mobile_Phone="", address={0,0,0,"",""}.
    [*=left]An overloaded constructor that takes the same parameters of the constructor in except Address for the address
    [*=left]Set and get functions for all data members. The setBloodgroup function should check the validity of the blood group before assigning it to bloodGroup by calling the function Is_BloodBroup_Valid described below.
    [*=left]Is_BloodGroup_Valid // takes a string as parameter and return true if it is a valid group and false if not. The only possible blood groups are A+, A-, B+, B-, O+, O-, AB+, AB-.
    [*=left]InputDetails// asks the user to enter all the details of a donor and then assign the values to the data members by calling the appropriate set functions.
    [*=left]printDetails // Print the details (IdNumber,name, bloodGroup, home phone, mobile phone, and address) of the donor
8. Destructor function.
PART A
Write the class BloodDonor and the code of the member functions.
PART B
Write a main function which includes the following:​


  1. [*=left]Creates an instance (object) named donor1 of type BloodDonor with id=567JJ9, name is
    Ahmed, blood group is B+, home phone="17123456", mobile phone="39999999",
    address={ l,l,l,"Manama","Bahrain"}-
    [*=left]Write a statement to change the mobile phone to "39888888".
    [*=left]Write a statement to print the mobile phone.
    [*=left]Write a statement to print the details of donor.
    [*=left]Create another object named donor2 of type BloodDonor.
    [*=left]Ask the user to enter the details of the donor2 by calling InputDetails function
    [*=left]Print the details of donor2.



يطلع 7 ايرور​


Set and get functions for all data members. The setBloodgroup function should check the validity of the blood group before assigning it to bloodGroup by calling the function Is_BloodBroup_Valid described below.

هذا السؤال بدون أخطاء بس ما أدري صح أو لا " مثل ما السؤال طالب " .. :nosweat:
نخلص الريض ونرجع ليكم .. :rolleyes2:

كود:
//Noise-X
#include<iostream>
#include<string>
using namespace std;
struct Address{
	int houseNo;
	int roadNo;
	int blockNo;
	string city;
	string country;
};
class BloodDonor
{
private:
	long IdNumber;
	string name;
	string bloodGroup;
	string home_Phone;
	string mobile_Phone;
	Address address;
public:
	BloodDonor(long =0, string =" ",string =" ",string =" ",string =" ",int =0,int =0,int =0,string =" ",string =" ");
	~BloodDonor();
	BloodDonor(long id, string n,string bg,string h,string m);
	void setIdNumber(long);
	void setname(string);
	void setbloodGroup(string);
	void sethome_Phone(string);
	void setmobile_Phone(string);
	void setaddress(int,int,int,string,string,Address); 
	long getIDNumber();
	string getname();
	string getbloodGroup();
	string gethome_Phone();
	string getmobile_Phone();
	void getaddress(int&,int&,int&,string&,string&,Address);
	bool Is_BloodBroup_Valid(string E);
	void InputDetails();
	void printDetails();
};
BloodDonor::BloodDonor (long id, string n,string bg,string hp,string mp,int h,int r,int b,string ci,string co)
{
	setIdNumber(id);
	setname(n);
	setbloodGroup(bg);
	sethome_Phone(hp);
	setmobile_Phone(mp);
	setaddress(h,r,b,ci,co,address);
}
BloodDonor::BloodDonor(long id, string n,string bg,string hp,string mp)
{
	setIdNumber(id);
	setname(n);
	setbloodGroup(bg);
	sethome_Phone(hp);
	setmobile_Phone(mp);
}
void BloodDonor::setIdNumber(long id)
{
IdNumber=id;
}
void BloodDonor::setname(string n)
{
name=n;
}
void BloodDonor::setbloodGroup(string bg)
{
bloodGroup=bg;
}
void BloodDonor::sethome_Phone(string hp)
{
home_Phone=hp;
}
void BloodDonor::setmobile_Phone(string mp)
{
mobile_Phone=mp;
}
void BloodDonor::setaddress(int h,int r,int b,string ci,string co,Address address)
{
	address.houseNo=h;
	address.roadNo=r;
	address.blockNo=b;
	address.city=ci;
	address.country=co;
}
long BloodDonor::getIDNumber()
{
	return IdNumber;
}
string BloodDonor::getname()
{
	return name;
}
string BloodDonor::getbloodGroup()
{
	return bloodGroup;
}
string BloodDonor::gethome_Phone()
{
	return home_Phone;
}
string BloodDonor::getmobile_Phone()
{
	return mobile_Phone;
}
void BloodDonor::getaddress(int &h,int &r,int &b,string &ci,string &co,Address address)
{
	h=address.houseNo;
	r=address.roadNo;
	b=address.blockNo;
	ci=address.city;
	co=address.country;
}
bool BloodDonor::Is_BloodBroup_Valid(string BG)
{
	if(BG=="A+"||BG== "A-"||BG== "B+"||BG== "B-"||BG== "0+"||BG== "0-"||BG=="AB+"||BG=="AB")
	return true;
	else
	return false;
}
void BloodDonor::InputDetails()
{
	cout<<"enter your IdNumber, name, blood group, home phone, mobile phone, house number,block number, city and your country"<<endl;
	cin>>IdNumber>>name>>bloodGroup>>home_Phone>>mobile_Phone;
	cin>>address.houseNo>>address.blockNo>>address.roadNo>>address.city>>address.country;
}
void BloodDonor::printDetails()
{
cout<<"Id number="<<IdNumber<<"\nname="<<name<<"\nblood group="<<bloodGroup<<"\nhome phone="<<home_Phone<<"\nmobile phone="<<mobile_Phone;
cout<<"\naddress="<<address.houseNo<<address.blockNo<<address.roadNo<<address.city<<address.country<<endl<<endl;
}
BloodDonor::~BloodDonor()
{cout<<"Clear Done"<<endl;}
int main()
{	
	BloodDonor donor1 (56789,"Ahmed","B+","17123456","39999999",1,1,1,"manama","Bahrain");
	donor1.setmobile_Phone("39688888");
	cout<<donor1.getmobile_Phone();
	donor1.printDetails();
	long id;
	string n,bg,hp,mp,city,country;
	int hn,rn,bn;
	cout<<"Enter your id:";
	cin>>id;
	cout<<"Enter your name:";
	cin>>n;
	cout<<"Enter your boodgoup:";
	cin>>bg;
	cout<<"Enter your home phone:";
	cin>>hp;
	cout<<"Enter your mobile phone:";
	cin>>mp;
	cout<<"Enter your house number:";
	cin>>hn;
	cout<<"Enter your road number:";
	cin>>rn;
	cout<<"Enter your block number:";
	cin>>bn;
	cout<<"Enter your city name:";
	cin>>city;
	cout<<"Enter your country name:";
	cin>>country;
	BloodDonor donor2(id,n,bg,hp,mp,hn,rn,bn,city,country);
	donor2.printDetails();
	return 0;
}
 
اعضاء الملتقى الكرام
رجاءا اي برنامج ينعرض في المنتدى لا تسوون له كوبي بيست
انتون بهذي الطريقة ماتستفيدون شي بالعكس يصير فيه تطابق في الاسايمينتات والكل يحصل صفر
تخربون ع نفسكم وع اللي رفع الحل

وبعدين عاد ماتوصل ان يطرش البرنامج مع توقيع العضو اللي سواه ,, يعني تخبر الدكتورة اشكرا انا مسوي كوبي بيست وماقريت الحل:smile:
​
 
اعضاء الملتقى الكرام
رجاءا اي برنامج ينعرض في المنتدى لا تسوون له كوبي بيست
انتون بهذي الطريقة ماتستفيدون شي بالعكس يصير فيه تطابق في الاسايمينتات والكل يحصل صفر
تخربون ع نفسكم وع اللي رفع الحل

وبعدين عاد ماتوصل ان يطرش البرنامج مع توقيع العضو اللي سواه ,, يعني تخبر الدكتورة اشكرا انا مسوي كوبي بيست وماقريت الحل:smile:
​

:RpS_blink: ..
 
. هذا السؤال بدون أخطاء بس ما أدري صح أو لا " مثل ما السؤال طالب " ..
نخلص الريض ونرجع ليكم ..

انزين مايصير نخلي ال void set كلهم في فنكشن وحدة !! ؟؟ :mellow:

اني كنت فاهمة السؤال طول الوقت هيك :no:
 
اعضاء الملتقى الكرام
رجاءا اي برنامج ينعرض في المنتدى لا تسوون له كوبي بيست
انتون بهذي الطريقة ماتستفيدون شي بالعكس يصير فيه تطابق في الاسايمينتات والكل يحصل صفر
تخربون ع نفسكم وع اللي رفع الحل

وبعدين عاد ماتوصل ان يطرش البرنامج مع توقيع العضو اللي سواه ,, يعني تخبر الدكتورة اشكرا انا مسوي كوبي بيست وماقريت الحل:smile:

​

إضافة إلى هذا
المسموح لكل برنامج يكتبه طالبين فقط
يعني لو ثلاثة طلاب نفس البرنامج أو الكود
الثلاثة يحصلون صفر
و هذا تعرضت له لما أخذت المقرر
كنت في البداية أرسل البرنامج للطلاب في السكشن بالإيميل
لكن بعد هذا وقفت أرسل لأحد شيء
 

السلام عليكم
لو سمحتوواا ممكن أحد يسااعدني
​


The first part
(1) Define and Implement a class named BankAccount. The data members of the class BankAccount are: AccountNumber (long), Name (string), and Balance (float). In addition, the class BankAccount contains the following member functions:


- Set functions for each of the data member.
- Get functions for each of the data member.
- DisplayAccountDetails that prints (on the screen) all the information about the Account.
- A Constructor with default values ​​parameters where the default values ​​are 999 for AccountNumber, "" for Name, and 0.0 for Balance.
- A destructor function that displays the message "Object deleted".




(2) Write a main function to test your class, as follow:
a. Write one statement to define an object named myAccount from the class BankAccount with values ​​of 9876543, "Customer", 2000 for the data members AccountNumber, Name, and Balance respectively.


b. Write statements that will withdraw an amount of 1000 from the account myAccount then prints the following messages:
Opening Balance:????
Amount of Withdrarwal: 1000.
Remaining Balance:????


Where??? are the values ​​of the previous balance (before the withdrawal) and the new balance (after the withdrawal) respectively. Use values ​​from the object myAccount. Do not put values ​​for these numbers yourself.






Part II






(1) Complete the class defined in the previous exercise to include the following functions:


• Withdraw function which is used to withdraw a certain amount X from the Account. It should check that the balance in the account is at least equal to X (ie X or more) before it allows the withdrawal and reduce the Balance by X.
• Deposit which is used to Deposit a certain amount Y into the Account. It should of course increase the Balance by Y.
• IsAccountEmpty which returns true if the Balance is less than or equal to zero. Otherwise it returns false.


(2) Write a main function to test your class as follow:


- Write one statement to define an array named AccountList with size 300 that contains objects of class BankAccount.


- Write statements to print on the screen all the empty Accounts in AccountList (that have a balance of zero or less). Assume that the list length is 100.
​
 
(1) Define and Implement a class named BankAccount. The data members of the class BankAccount are: AccountNumber (long), Name (string), and Balance (float). In addition, the class BankAccount contains the following member functions:

- Set functions for each of the data member.
- Get functions for each of the data member.
- DisplayAccountDetails that prints (on the screen) all the information about the Account.
- A Constructor with default values parameters where the default values are 999 for AccountNumber, "" for Name, and 0.0 for Balance.
- A destructor function that displays the message “Object deleted”.


(2) Write a main function to test your class, as follow:
a. Write one statement to define an object named myAccount from the class BankAccount with values of 9876543, "Customer”, 2000 for the data members AccountNumber, Name, and Balance respectively.

b. Write statements that will withdraw an amount of 1000 from the account myAccount then prints the following messages:
Opening Balance: ????
Amount of Withdrarwal: 1000.
Remaining Balance: ????

Where ??? are the values of the previous balance (before the withdrawal) and the new balance (after the withdrawal) respectively. Use values from the object myAccount. Do not put values for these numbers yourself
​
.

سلام عليكم .. ممكن مساعدتي في بارت 2 (B) ؟ مشيره في آخر السؤال؟
 
الحلول الجاهزة ممنوعة,, و سيحذف الرد,
و محاولات حل الاسايمنتات سيتم حذفها, حفاظاً على مصلحة الطلاب
فقط بامكانكم استفسار عن بعض انقاط للاسايمنت لا غير
​
 

السلام عليكم
لو سمحتوواا ممكن أحد يسااعدني
​


The first part
(1) Define and Implement a class named BankAccount. The data members of the class BankAccount are: AccountNumber (long), Name (string), and Balance (float). In addition, the class BankAccount contains the following member functions:


- Set functions for each of the data member.
- Get functions for each of the data member.
- DisplayAccountDetails that prints (on the screen) all the information about the Account.
- A Constructor with default values ​​parameters where the default values ​​are 999 for AccountNumber, "" for Name, and 0.0 for Balance.
- A destructor function that displays the message "Object deleted".




(2) Write a main function to test your class, as follow:
a. Write one statement to define an object named myAccount from the class BankAccount with values ​​of 9876543, "Customer", 2000 for the data members AccountNumber, Name, and Balance respectively.


b. Write statements that will withdraw an amount of 1000 from the account myAccount then prints the following messages:
Opening Balance:????
Amount of Withdrarwal: 1000.
Remaining Balance:????


Where??? are the values ​​of the previous balance (before the withdrawal) and the new balance (after the withdrawal) respectively. Use values ​​from the object myAccount. Do not put values ​​for these numbers yourself.






Part II






(1) Complete the class defined in the previous exercise to include the following functions:


• Withdraw function which is used to withdraw a certain amount X from the Account. It should check that the balance in the account is at least equal to X (ie X or more) before it allows the withdrawal and reduce the Balance by X.
• Deposit which is used to Deposit a certain amount Y into the Account. It should of course increase the Balance by Y.
• IsAccountEmpty which returns true if the Balance is less than or equal to zero. Otherwise it returns false.


(2) Write a main function to test your class as follow:


- Write one statement to define an array named AccountList with size 300 that contains objects of class BankAccount.


- Write statements to print on the screen all the empty Accounts in AccountList (that have a balance of zero or less). Assume that the list length is 100.
​

(1) Define and Implement a class named BankAccount. The data members of the class BankAccount are: AccountNumber (long), Name (string), and Balance (float). In addition, the class BankAccount contains the following member functions:

- Set functions for each of the data member.
- Get functions for each of the data member.
- DisplayAccountDetails that prints (on the screen) all the information about the Account.
- A Constructor with default values parameters where the default values are 999 for AccountNumber, "" for Name, and 0.0 for Balance.
- A destructor function that displays the message “Object deleted”.


(2) Write a main function to test your class, as follow:
a. Write one statement to define an object named myAccount from the class BankAccount with values of 9876543, "Customer”, 2000 for the data members AccountNumber, Name, and Balance respectively.

b. Write statements that will withdraw an amount of 1000 from the account myAccount then prints the following messages:
Opening Balance: ????
Amount of Withdrarwal: 1000.
Remaining Balance: ????

Where ??? are the values of the previous balance (before the withdrawal) and the new balance (after the withdrawal) respectively. Use values from the object myAccount. Do not put values for these numbers yourself
​
.

سلام عليكم .. ممكن مساعدتي في بارت 2 (B) ؟ مشيره في آخر السؤال؟


عليكم السلام و الرحمة

المطلوب برنامج
فيه كلاس

class BankAccount
{

- private:

بتحطين الممبرز الي محددين بالسؤال مع النوع

- public:

* set, get
نفس الأمئلة الي يعطيكم الدكتور , الفرق بطبقين عالبيانات الي في السؤال

* DisplayAccountDetails
سي آوت عادية الى كل البيانات في البرايفت بالسؤال بأي ترتيب و أي شكل تبينه

* constructer with default values parameters
الكونستراكتر على اسم الكلاس تكون و بدون رتيرن تايب
اهني محددين عندنا انها وذ ديفولت .
يعني قيمة للبيانات تكون اساسية قبل أي اضافة من اليوزر
و عاطينا القيم .. اذا ما عطونا نحط من عندنا
BankAccount(long accNum = 999,.....ect);

* destructure
syntix: ~className();
داخلها مسج مثلاً
cout<<"objects deleted";

};

بعدين الفنكشنات الي في الكلاس بتحطينهم كامل

main:-

{

*defined object
syntix: className objectName;
objectName(values);

*ستيتمنت تسحب 1000 من القيمة الموجودة في الاوبجكت الي سويناه
اهني بنحتاج ناخذ القيمة الأساسية عن طريق فنكشن get
cout<<"Opening Balance: " << getBalance (call to function getBalance)
cout<<...المبلغ المسحوب = 1000 حسب السؤال
cout<<...المبلغ المتبقي

*cout<<الجملة الطويلة
القيمة القبلية بناخذها بفنكشن قِت
القيمة الحالية بنحط متغير الى المبلغ بعد السحب عشان نحطه في السي آوت

}


بارت 2

* مطلوب اضيفين 3 فنكشنات
الأولى: فنكشن تستخددم عشان تنقص قيمة المبلغ الأصلي من المبلغ الي يتحدد عشان ينسحب
فبتجيك ان في الأكاونت قد المبلغ الي بتسحبه أو أكثر قبل السحب

الثانية: اهني يزيد قيمة المبلغ الموجودة بالمبلغ الي بيدخله صاحب الأكاونت

في الفنكشنتين بنحتاج قيمة السحب أو قيمة الايداع و أتوقع يكونون براميتر

الثالثة: اتجيك الحساب فيه مبلغ او لا

* في المين ديفايند أري حجمه 300 فيه أوبجكت من نوع الكلاس الي عندنا
BankAccount AccountList[300];
بكون في هذا الكلاس كل جزء منه أوبجكت .. الأوبجكت فيه كل القيم الأساسية الي في البرايفت

* بما إن عندنا أري بنحتاج فور لوب
داخله اف ستيتمنت حسب الموجود بالسؤال
اذا اتحقق الشرط بسوي كول فنكشن الى البرنت
تطبع قيم الآي الي تحقق عندها الشرط " الأوبجكت"
AccountList.print();


أي استفسار ثاني حاضرين
و طبعاً الأقواس تعرفون ليهم شلون طريقتهم
بس بالمنتدى يطلعون بهالطريقة ما ادري ليش
احتمال من المتصفح عندي ^^"
​
 
انزين مايصير نخلي ال void set كلهم في فنكشن وحدة !! ؟؟ :mellow:

اني كنت فاهمة السؤال طول الوقت هيك :no:

يب يصير والسؤال طالب نخليهم كلهم مع بعض .. :nosweat:
بس أنا عدلت الأخطاء ما شفت السؤال :whistling:

هذي إجابة السؤال الصحيحة ..

كود:
//Noise-X
#include<iostream>
#include<string>
using namespace std;
struct Address{
	int houseNo;
	int roadNo;
	int blockNo;
	string city;
	string country;
};
class BloodDonor
{
private:
	long int IdNumber;
	string name;
	string bloodGroup;
	string home_Phone;
	string mobile_Phone;
	Address address;
public:
	BloodDonor(long =0, string =" ",string =" ",string =" ",string =" ",int =0,int =0,int =0,string =" ",string =" ");
	~BloodDonor();
	BloodDonor(long id, string n,string bg,string h,string m);
	void set(long,string,string,string,string);
	void setaddress(int,int,int,string,string,Address); 
	void get (long&,string&,string&,string&,string&);
	void getaddress(int&,int&,int&,string&,string&,Address);
	void setBloodgroup ();
	bool Is_BloodBroup_Valid(string E);
	void InputDetails();
	void printDetails();
};
BloodDonor::BloodDonor (long id, string n,string bg,string hp,string mp,int h,int r,int b,string ci,string co)
{
	IdNumber=id;
	name=n;
	bloodGroup=bg;
	home_Phone=hp;
	mobile_Phone=mp;
	address.houseNo=h;
	address.roadNo=r;
	address.blockNo=b;
	address.city=ci;
	address.country=co;
	
}
BloodDonor::BloodDonor(long int id, string n,string bg,string hp,string mp)
{
	id=IdNumber;
	n=name;
	bg=bloodGroup;
	hp=home_Phone;
	mp=mobile_Phone;
}
void BloodDonor::set (long int id, string n,string bg,string h,string m)
{
	IdNumber=id;
	name=n;
	bloodGroup=bg;
	home_Phone=h;
	mobile_Phone=m;
}
void BloodDonor::get (long int &id, string &n,string &bg,string &h,string &m)
{
	id=IdNumber;
	n=name;
	bg=bloodGroup;
	h=home_Phone;
	m=mobile_Phone;
}
void BloodDonor::setaddress(int h,int r,int b,string ci,string co,Address address)
{
	address.houseNo=h;
	address.roadNo=r;
	address.blockNo=b;
	address.city=ci;
	address.country=co;
}
void BloodDonor::getaddress(int &h,int &r,int &b,string &ci,string &co,Address address)
{
	h=address.houseNo;
	r=address.roadNo;
	b=address.blockNo;
	ci=address.city;
	co=address.country;
}
void BloodDonor::setBloodgroup ()
{
	int c=1;
	string BG;
	do {
		cin>>BG;
		if (Is_BloodBroup_Valid(BG))
			bloodGroup=BG;
	}while(c>0);
}
bool BloodDonor::Is_BloodBroup_Valid(string BG)
{
	if(BG=="A+"||BG== "A-"||BG== "B+"||BG== "B-"||BG== "O+"||BG== "O-"||BG=="AB+"||BG=="AB")
	return true;
	else
	{
		cout<<"BloodBroup_Valid\n";
		return false;
	}
}
void BloodDonor::InputDetails()
{
	cout<<"Enter your id: ";
	cin>>IdNumber;
	cout<<"Enter your name: ";
	cin>>name;
	cout<<"Enter your boodgoup: ";
	setBloodgroup();
	cout<<"Enter your home phone: ";
	cin>>home_Phone;
	cout<<"Enter your mobile phone: ";
	cin>>mobile_Phone;
	cout<<"Enter your house number: ";
	cin>>address.houseNo;
	cout<<"Enter your road number: ";
	cin>>address.roadNo;
	cout<<"Enter your block number: ";
	cin>>address.blockNo;
	cout<<"Enter your city name: ";
	cin>>address.city;
	cout<<"Enter your country name: ";
	cin>>address.country;
	cout<<endl;
}
void BloodDonor::printDetails()
{
	cout<<"Enter your id: "<<IdNumber<<endl;
	cout<<"Enter your name: "<<name<<endl;
	cout<<"Enter your boodgoup: "<<bloodGroup<<endl;
	cout<<"Enter your home phone: "<<home_Phone<<endl;
	cout<<"Enter your mobile phone: "<<mobile_Phone<<endl;
	cout<<"Enter your house number: "<<address.houseNo<<endl;
	cout<<"Enter your road number: "<<address.roadNo<<endl;
	cout<<"Enter your block number: "<<address.blockNo<<endl;
	cout<<"Enter your city name: "<<address.city<<endl;
	cout<<"Enter your country name: "<<address.country<<endl<<endl;
}
BloodDonor::~BloodDonor()
{cout<<"Clear Done"<<endl;}
int main()
{
	long id;
	string n,bg,hp,mp,city,country;
	BloodDonor donor1 (56789,"Ahmed","B+","17123456","39999999",1,1,1,"manama","Bahrain");
	donor1.get(id,n,bg,hp,mp);
	donor1.set(id,n,bg,hp,"39688888");
	donor1.get(id,n,bg,hp,mp);
	cout<<"Mobile phone : "<<mp<<endl<<endl;
	donor1.printDetails();
	BloodDonor donor2;
	donor2.InputDetails();
	donor2.printDetails();
	return 0;
}
 
أخواني مثل ما ذكر الاخ قاسم
كل رد فيه برامج كاملة بينحذف لأن يتضررون الطلبة ,,

اذا أحد عنده بروقرام كامل فيه مجموعة أخطاء
يقدر يرفق في رده برنت سكرين للأخطاء من البرنامج
أو يحط الجزء من الكود الي فيه خطأ

بس لا تحطون الكود للأسايمنت كاااامل عشان جهدكم لا يُقتبس

+ ممنوع الاجابات الجاهزة الكاملة

نرجو تعاونكم .. و فائدة هالشي ترجع ليكم مو لينا :rolleyes2:
 
عودة
أعلى أسفل