7.while迴圈

#include <bits/stdc++.h>
using namespace std;
int main(){
    int t;
    cin >> t;
    /*
        while(繼續執行的條件){
            ........
            ........
        }
    */
    while(t--) // t-- 就是 t = t - 1
        cout << t << endl;
    return 0;
}

results matching ""

    No results matching ""