Basic Arrays 3

Create an array that can hold 1000 integers. Fill the array with random numbers in the range 10-99. Then display the contents of the array on the screen. You must use a loop.

If you're careful to only pick random numbers from 10 to 99 and you put two spaces after each number, then your output will line up like mine.

And if you've forgotten how to pick random numbers in a certain range, you can check out my random ranges visualizer.

81  69  34  39  35  19  68  14  93  91  96  90  67  82  15  75  13  34  39  88
89  70  53  31  52  79  89  97  36  56  33  61  67  98  57  85  90  55  82  94
50  91  96  73  60  58  56  46  64  71  79  54  40  79  24  68  21  37  55  33
59  46  95  12  98  12  92  78  94  14  17  16  15  99  36  40  20  69  29  42
88  50  31  60  65  57  79  53  30  84  28  97  66  23  88  97  18  86  44  79
90  63  59  97  11  28  57  88  71  89  42  84  28  55  42  13  16  48  58  68
49  92  53  25  26  25  31  53  91  50  73  80  21  86  87  60  63  59  44  39
59  25  46  11  14  21  52  97  35  27  56  49  75  13  30  57  20  74  56  39
35  46  20  62  21  59  87  43  81  24  75  42  79  26  40  19  92  50  57  32
26  71  10  65  62  98  44  69  60  66  51  72  87  24  82  36  81  69  22  88
68  73  28  49  74  15  19  44  11  11  73  55  23  73  30  94  85  92  11  53
12  69  70  17  51  40  57  28  94  93  93  90  64  45  50  90  65  66  15  42
97  69  48  96  15  11  29  19  90  73  76  33  19  14  37  20  15  69  47  58
24  81  84  34  84  26  20  49  98  16  71  47  75  18  28  26  25  21  39  42
17  58  40  10  29  17  55  35  18  59  20  88  49  42  74  65  75  52  41  93
96  19  82  34  29  71  30  86  91  15  36  85  28  24  43  38  17  76  95  30
31  48  15  96  47  56  67  70  87  16  42  96  21  20  75  70  68  11  21  50
55  51  93  56  20  21  89  49  13  33  18  62  72  95  94  62  88  91  26  46
81  28  70  87  43  30  54  82  54  39  68  54  22  99  61  29  77  19  74  87
32  44  65  32  73  88  58  23  32  23  62  27  45  84  44  33  60  23  62  64
59  90  20  49  33  11  48  90  39  49  64  54  21  52  66  61  18  65  97  59
22  53  18  80  12  67  88  57  73  65  14  82  41  73  22  42  58  69  94  87
11  35  64  81  34  30  41  16  99  42  74  96  92  47  62  49  31  34  24  99
22  76  96  15  25  77  49  71  98  60  17  67  86  52  25  17  25  67  17  26
53  42  40  46  10  36  33  67  15  79  48  69  57  91  29  36  50  71  39  10
22  55  76  93  80  48  74  85  26  64  93  83  33  30  65  34  96  12  44  43
36  13  64  59  23  70  87  73  87  12  96  65  83  79  23  92  56  86  39  57
94  46  62  75  60  12  14  15  82  91  43  85  64  73  79  14  38  46  63  82
17  49  56  22  64  10  84  67  66  85  78  22  72  53  33  18  43  90  94  61
92  52  42  95  32  61  92  24  22  23  57  96  27  45  41  97  24  52  74  23
28  52  94  64  24  47  62  48  46  72  27  50  15  37  10  75  66  53  42  81
69  12  76  84  43  79  89  75  76  89  93  13  32  85  67  24  97  65  14  62
10  47  25  62  73  40  71  66  11  81  22  33  22  90  55  39  26  63  14  45
51  71  68  26  63  71  19  95  95  93  18  17  20  56  28  74  23  85  44  83
54  99  77  57  97  14  13  54  44  35  27  55  29  58  41  35  26  23  64  53
11  55  92  10  42  57  73  59  21  92  24  53  65  60  16  26  53  69  49  61
66  87  34  15  19  85  33  96  16  11  57  11  19  38  86  55  21  12  19  21
75  69  92  45  90  96  67  33  88  99  68  76  22  60  60  11  42  62  44  23
65  74  15  92  47  35  83  79  71  86  44  86  68  97  60  66  14  75  45  56
12  98  11  10  16  38  54  83  51  83  49  62  63  24  68  13  31  13  41  34
59  35  12  88  12  21  55  93  27  92  27  14  39  58  31  39  25  94  83  88
70  69  22  71  41  43  34  45  27  26  77  11  39  32  96  78  67  58  54  84
19  26  96  14  29  92  11  28  68  91  93  74  53  13  84  99  70  11  91  70
75  55  87  16  57  17  58  13  75  79  65  51  75  33  87  54  22  63  48  45
71  79  12  40  52  71  62  38  77  36  88  53  94  88  58  20  28  11  48  59
74  33  52  78  76  38  42  20  80  99  53  64  81  79  16  30  18  46  79  70
43  83  14  71  99  64  84  94  20  54  74  40  37  22  96  34  83  85  11  99
64  21  37  80  68  34  17  87  88  53  29  27  42  44  59  37  52  85  64  34
93  23  35  13  46  14  59  87  42  78  52  89  14  52  37  30  74  22  70  79
18  80  32  34  84  98  68  27  89  30  44  86  57  49  51  65  71  30  37  63



©2003–2016 Graham Mitchell

This assignment is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0 United States License.
Creative Commons License