|
@@ -294,7 +294,7 @@ Here are some code snippets for common reading tasks. Observe that all of them:
|
294
|
294
|
##Laboratory Session:
|
295
|
295
|
|
296
|
296
|
|
297
|
|
-### Exercise 0 - Download and understand the code
|
|
297
|
+### Exercise 1 - Download and understand the code
|
298
|
298
|
|
299
|
299
|
|
300
|
300
|
####Instructions
|
|
@@ -332,7 +332,7 @@ There are two additional functions that you need to know:
|
332
|
332
|
2. `void drawPoints(GISPOI* gisLocations, unsigned int size);`: Given an array of `GISPOI` objects and their size, displays their locations as points in the map.
|
333
|
333
|
|
334
|
334
|
|
335
|
|
-### Exercise 1 - Read the georeferenced points into an array
|
|
335
|
+### Exercise 2 - Read the georeferenced points into an array
|
336
|
336
|
|
337
|
337
|
|
338
|
338
|
Remember that you will only be changing code in the `main.cpp` file. Your first task will be to add code to read the entire contents of a file into an array of `GISPOI` objects.
|
|
@@ -374,7 +374,7 @@ Remember that you will only be changing code in the `main.cpp` file. Your first
|
374
|
374
|
|
375
|
375
|
|
376
|
376
|
|
377
|
|
-### Exercise 2 - Max and min functions
|
|
377
|
+### Exercise 3 - Max and min functions
|
378
|
378
|
|
379
|
379
|
|
380
|
380
|
Once you have the information of georeferenced cities in the array of objects, you can start processing them in many interesting ways. We will start with some basic operations.
|
|
@@ -396,7 +396,7 @@ Once you have the information of georeferenced cities in the array of objects, y
|
396
|
396
|
|
397
|
397
|
|
398
|
398
|
|
399
|
|
-### Exercise 3 - Compute the cycle distance
|
|
399
|
+### Exercise 4 - Compute the cycle distance
|
400
|
400
|
|
401
|
401
|
|
402
|
402
|
1. Read the documentation and implement the function `double cycleDistance(GISPOI A[], int size, int P[])`. Invoke the function from `main()` as indicated in the comments inside the `main()` function:
|
|
@@ -406,7 +406,7 @@ Once you have the information of georeferenced cities in the array of objects, y
|
406
|
406
|
|
407
|
407
|
|
408
|
408
|
|
409
|
|
-### Exercise 4 - More fun!
|
|
409
|
+### Exercise 5 - More fun!
|
410
|
410
|
|
411
|
411
|
|
412
|
412
|
1. Change your code so that it now opens the `pr.txt` file. Validate your results and marvel at your great achievement!
|