Read OnLine Cpp Program Example
2 - VARIABLE CONCEPT | |
---|---|
PRAC 3 | PRAC 4 |
//wap to print add #include<iostream.h> #include<conio.h> void main() { int a,b,ans; clrscr(); cout<<"Enter 1st number:"; cin>>a cout<<"Enter 2nd number:"; cin>b; ans=a+b; cout<<ans; getch(); } -----output----- Enter 1st number:23 Enter 2nd number:34 add=57 |
//wap to print char #include<iostream.h> #include<conio.h> void main() { char a; clrscr(); a='A'; cout<<a; getch(); } -----output------ A |
Previous | Next |
Download | Download |