C++的新写法

For Loop:

=== old

    for (int i = 0; i < argCount; ++i)

    {

        std::cout << arr[i];

    }

=== new

    for (auto i:arr)

    {

        std::cout << i <<" ";

    }

 

    

posted on 2015-10-02 11:06  vczh_tonyc  阅读(187)  评论(0编辑  收藏  举报

导航