for loop

for loop while loop bilan bir xil. Faqatgina yozilishida ozgina farq qilinadi.

Syntax of for loop:
for(initialization; condition; ++/–)
{
statement
}

Masalan:

#include <iostream>

using namespace std;

int main()
{
for(int n = 1; n <…


This content originally appeared on DEV Community and was authored by Sanjar Rashidov

for loop while loop bilan bir xil. Faqatgina yozilishida ozgina farq qilinadi.

Syntax of for loop:
for(initialization; condition; ++/--)
{
statement
}

Masalan:

#include <iostream>

using namespace std;

int main()
{
    for(int n = 1; n <= 7; n++)
    {
        cout << n << endl;
    }

    return 0;
}

for loopdagi o'zgaruvchi for loopdan tashqarida ishlamaydi!


This content originally appeared on DEV Community and was authored by Sanjar Rashidov


Print Share Comment Cite Upload Translate Updates
APA

Sanjar Rashidov | Sciencx (2024-11-02T11:15:15+00:00) for loop. Retrieved from https://www.scien.cx/2024/11/02/for-loop-2/

MLA
" » for loop." Sanjar Rashidov | Sciencx - Saturday November 2, 2024, https://www.scien.cx/2024/11/02/for-loop-2/
HARVARD
Sanjar Rashidov | Sciencx Saturday November 2, 2024 » for loop., viewed ,<https://www.scien.cx/2024/11/02/for-loop-2/>
VANCOUVER
Sanjar Rashidov | Sciencx - » for loop. [Internet]. [Accessed ]. Available from: https://www.scien.cx/2024/11/02/for-loop-2/
CHICAGO
" » for loop." Sanjar Rashidov | Sciencx - Accessed . https://www.scien.cx/2024/11/02/for-loop-2/
IEEE
" » for loop." Sanjar Rashidov | Sciencx [Online]. Available: https://www.scien.cx/2024/11/02/for-loop-2/. [Accessed: ]
rf:citation
» for loop | Sanjar Rashidov | Sciencx | https://www.scien.cx/2024/11/02/for-loop-2/ |

Please log in to upload a file.




There are no updates yet.
Click the Upload button above to add an update.

You must be logged in to translate posts. Please log in or register.