Explain the FOR loop with a help of a code.
Answer / Prakash Kumar Jha
A For loop is a control structure used in C++ to iterate a specific number of times. Here's an example:
```
for(int i = 0; i < 10; i++) {
cout << i << endl;
}
| Is This Answer Correct ? | 0 Yes | 0 No |
C++ Public access specifier instead of Private – What is bad ?
How to invoke a C function using a C++ program?
How to run C++ program in cmd
what is a pragma in C++?
Explain about Searching and sorting algorithms with complexities
How to generate random numbers in C++ with a range?
Write a program that ask for user input from 5 to 9 then calculate the average
What are string library functions(syntax).
Is there a difference between class and struct?
What is the purpose of a constructor? Destructor?
Write a C++ Program to find Square Root of a number using sqrt() function.
When would you use a pointer? A reference?