|
@@ -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!
|
|
@@ -420,7 +420,7 @@ Once you have the information of georeferenced cities in the array of objects, y
|
420
|
420
|
---
|
421
|
421
|
|
422
|
422
|
|
423
|
|
-##Deliverables
|
|
423
|
+## Deliverables
|
424
|
424
|
|
425
|
425
|
|
426
|
426
|
Use "Deliverable" in Moodle to hand in the `main.cpp` file. Remember to use good programming techniques, include the name of the programmers involved, and document your program.
|