2015-02-20 00:35:01 -05:00
|
|
|
Show a nested loop which searches a two-dimensional array filled with random numbers uniformly distributed over <math>[1,\ldots,20]</math>.
|
2016-12-05 22:15:40 +01:00
|
|
|
|
2015-02-20 00:35:01 -05:00
|
|
|
The loops iterate rows and columns of the array printing the elements until the value <math>20</math> is met.
|
2016-12-05 22:15:40 +01:00
|
|
|
|
2015-02-20 00:35:01 -05:00
|
|
|
Specifically, this task also shows how to [[Loop/Break|break]] out of nested loops.
|
2018-06-22 20:57:24 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
;Related tasks:
|
|
|
|
|
* [[Loop over multiple arrays simultaneously]]
|
|
|
|
|
* [[Loops/Break]]
|
|
|
|
|
* [[Loops/Continue]]
|
|
|
|
|
* [[Loops/Do-while]]
|
|
|
|
|
* [[Loops/Downward for]]
|
|
|
|
|
* [[Loops/For]]
|
|
|
|
|
* [[Loops/For with a specified step]]
|
|
|
|
|
* [[Loops/Foreach]]
|
|
|
|
|
* [[Loops/Increment loop index within loop body]]
|
|
|
|
|
* [[Loops/Infinite]]
|
|
|
|
|
* [[Loops/N plus one half]]
|
|
|
|
|
* [[Loops/Nested]]
|
|
|
|
|
* [[Loops/While]]
|
2019-09-12 10:33:56 -07:00
|
|
|
* [[Loops/with multiple ranges]]
|
|
|
|
|
* [[Loops/Wrong ranges]]
|
2016-12-05 22:15:40 +01:00
|
|
|
<br><br>
|