#include<iostream>
#include<string>
using namespace std;
struct laptopdata
{
string name;
int price;
string model;
string colour;
int battarylife;
string storage;
};
int main()
{
laptopdata ld;
cout<<"please enter the the name of the laptop:";
cin>>ld.name;
cout<<"please enter the price of the laptop:";
cin>>ld.price;
cout<<"please enter the model of the laptop:";
cin>>ld.model;
cout<<"please enter the colour of the laptop:";
cin>>ld.colour;
cout<<"please enter the battery life of the laptop:";
cin>>ld.battarylife;
cout<<"please enter the storage of the laptop:";
cin>>ld.storage;
cout<<endl;
cout<<"information of laptop"<<endl;
cout<<endl;
cout<<"name of laptop:"<<ld.name<<endl;
cout<<"price of laptop:"<<ld.price<<endl;
cout<<"model of laptop:"<<ld.model<<endl;
cout<<"colour of laptop:"<<ld.colour<<endl;
cout<<"battery life of laptop:"<<ld.battarylife<<endl;
cout<<"the storage of the laptop:"<<ld.storage<<endl;
cout<<endl;
}
No comments:
Post a Comment