Write a program to accept item number,item name and price.
Print them in three different lines.
The program language is C++
Answers
Answered by
1
#include<iostream.h>
#include<conio.h>
void main()
{
clrscr();
int itnum, pr;
char itname;
cout<<"Enter the item number.";
cin>>intnum;
cout<<"Enter the item name.";
cin>>itname;
cout<<"Enter the item price.";
cin>>pr;
cout<<itnum;
cout<<"\n"<<itname;
cout<<"\n"<<pr;
getch();
}
#include<conio.h>
void main()
{
clrscr();
int itnum, pr;
char itname;
cout<<"Enter the item number.";
cin>>intnum;
cout<<"Enter the item name.";
cin>>itname;
cout<<"Enter the item price.";
cin>>pr;
cout<<itnum;
cout<<"\n"<<itname;
cout<<"\n"<<pr;
getch();
}
Answered by
0
Answer:
#include <iostream>
using namespace std;
int main()
{
int number;
cout << "Enter an integer: ";
cin >> number;
cout << "You entered " << number;
return 0
Similar questions