Skip to content

Commit 2fc5c7f

Browse files
committed
fixing single character cariables
1 parent bf1e052 commit 2fc5c7f

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

courses/ada_essentials/050_array_types/08-array_aggregates.rst

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -224,23 +224,23 @@ Quiz
224224
.. code:: Ada
225225
226226
type Array_T is array (1 .. 5) of Integer;
227-
X : Array_T;
228-
J : Integer := X'First;
227+
Foo : Array_T;
228+
Bar : Integer := Foo'First;
229229
230230
Which statement is correct?
231231

232-
A. ``X := (1, 2, 3, 4 => 4, 5 => 5);``
233-
B. :answermono:`X := (1..3 => 100, 4..5 => -100, others => -1);`
234-
C. ``X := (J => -1, J + 1..X'Last => 1);``
235-
D. ``X := (1..3 => 100, 3..5 => 200);``
232+
A. ``Foo := (1, 2, 3, 4 => 4, 5 => 5);``
233+
B. :answermono:`Foo := (1..3 => 100, 4..5 => -100, others => -1);`
234+
C. ``Foo := (Bar => -1, Bar + 1..Foo'Last => 1);``
235+
D. ``Foo := (1..3 => 100, 3..5 => 200);``
236236

237237
.. container:: animate
238238

239239
Explanations
240240

241241
A. Cannot mix positional and named notation
242242
B. Correct - others not needed but is allowed
243-
C. Either make :ada:`J` a :ada:`constant` or only use dynamic values
243+
C. Either make :ada:`Bar` a :ada:`constant` or only use dynamic values
244244
D. Overlapping index values (3 appears more than once)
245245

246246
------------------------

0 commit comments

Comments
 (0)