mirror of
https://codeberg.org/ziglings/exercises.git
synced 2026-06-11 01:20:00 +00:00
Edit comment above a for loop by reference line
This commit is contained in:
@@ -80,7 +80,7 @@ pub fn main() void {
|
|||||||
while (aliens_alive > 0) {
|
while (aliens_alive > 0) {
|
||||||
aliens_alive = 0;
|
aliens_alive = 0;
|
||||||
|
|
||||||
// Loop through every alien...
|
// Loop through every alien by reference by specifying that the capture value is a pointer
|
||||||
for (aliens) |*alien| {
|
for (aliens) |*alien| {
|
||||||
|
|
||||||
// *** Zap the Alien Here! ***
|
// *** Zap the Alien Here! ***
|
||||||
|
|||||||
Reference in New Issue
Block a user