Posts

Showing posts from July, 2017

how to work in C++ from basic to advance

Image
Q) Write a program which prints number from 1 to 10 in c++ from basic to advance .   This program used to print number from 1 to 10 in c++ from basic to advance. "Code of the program" #include<iostream> using namespace std; int main() { int a = 1; while (a <= 10){ cout << a << endl; a++; } system("pause"); } " Snippet of the program" Q)Write a program in which a user  inputs three numbers and displays the largest number. *)In this program, a user is asked to enter three numbers. this program finds out the largest number among three numbers entered by a user and displays it with proper message .this tutorial appears in c++ from basic to advance. RUN sample Example Enter three numbers: 78 98 16 Greatest number is 98 "Code of the program" #include<iostream> using namespace std; int main() { int a, b, c; cout << " Enter value