Home ยป Updates ยป Learn C++ Tutorial 9

Learn C++ Tutorial 9

In this tutorial, we have to discuss about some programs that are so easy.

We discuss two programs which are given below.

Write a program to that input name, age, and address from the user and then display their value on the screen.

String Program


using namespace std;

int main(){

char name[30],add[30];

int age;

cout<<“Please Enter The name:”;


cout<<“Please Enter The Address:”;


cout<<“Please Enter The age:”;


cout<<“Your name is :”<<name<<endl;
cout<<“Your address is :”<<add<<endl;
cout<<“Your age is :”<<age<<endl;


And other program is given below.

Write a program that inputs a character and display its ASCII Code.



using namespace std;

int main(){

char chr;
cout<<"Please Enter the Character:";


int num=chr;

cout<<"ASCII CODE of "<<chr<<" is :"<<num;


Must watch the video for practical

Click here to watch the Video

Thanks for Visiting


Related Posts