| |

VerySource

 Forgot password?
 Register
Search
Author: minotaurus

How to use iterator to operate a two-dimensional array created by vector?

[Copy link]

1

Threads

6

Posts

7.00

Credits

Newbie

Rank: 1

Credits
7.00

 China

 Author| Post time: 2020-1-28 23:36:01
| Show all posts
OK, thank you for pointing!
Reply

Use magic Report

0

Threads

1

Posts

2.00

Credits

Newbie

Rank: 1

Credits
2.00

 China

Post time: 2020-8-26 08:00:01
| Show all posts
If you define vector<vector<int>> a(3, vector<int>(4));//It is equivalent to a 3×4 integer array.

What about assigning values ​​to the element a[2][3]?
Reply

Use magic Report

You have to log in before you can reply Login | Register

Points Rules

Contact us|Archive|Mobile|CopyRight © 2008-2023|verysource.com ( 京ICP备17048824号-1 )

Quick Reply To Top Return to the list