Write a program to input an integer from the keyboard and display on the screen “WELL DONE” that many times.
Answer Posted / hr
#include<iostream>
#include<iomanip>
using namespace std;
int main()
{
int n;
char *str;
str="WELL DONE";
cout<<" Enter an integer value ";
cin>>n;
for(int i=0;i<n;i++)
{
cout<<str<<endl;
}
return 0;
}
OUTPUT:
Enter an integer value 5
WELL DONE
WELL DONE
WELL DONE
WELL DONE
WELL DONE
Is This Answer Correct ? | 0 Yes | 2 No |
Post New Answer View All Answers
Explain the difference between struct and class in terms of access modifier.
What is a base class?
What is namespace & why it is used in c++?
Can you please explain the difference between static and dynamic binding of functions?
How can we read/write Structures from/to data files?
please visit this site you'll find my question this is my homework please answer it if you can http://easyscience.org/ib/lofiversion/index.php/t36168.html
What is a class and object?
What is else if syntax?
the maximum length of a character constant can be a) 2 b) 1 c) 8
What is a lambda function c++?
Write about the retrieval of n number of objects during the process of delete[]p?
What do you understand by pure virtual function? Write about its use?
What is the arrow operator in c++?
What is the example of polymorphism?
Who calls main function?