blob: 19a857db577ee745f9380615aa6a0424f6b9eede (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
|
Comments: I get why this is such a small dataset - it's easy to share the file,
and you don't really need a lot of entries for this assignment,
since it's not about writing super efficient code.
Still, I'm not sure a dataset with 48 entries deserves to be called "large".
Output:
Entry # # ppl Dist. Fare Toll Total Fare/mi
1 3.00 1.30 7.50 0.00 7.50 5.77
2 1.00 11.41 32.00 5.76 37.76 3.31
3 1.00 4.60 15.00 5.76 20.76 4.51
4 2.00 6.75 23.00 0.00 23.00 3.41
5 1.00 3.84 15.00 0.00 15.00 3.91
6 6.00 1.64 9.50 0.00 9.50 5.79
7 1.00 16.08 44.50 0.00 44.50 2.77
8 2.00 7.40 24.50 6.12 30.62 4.14
9 5.00 1.70 8.00 0.00 8.00 4.71
10 0.00 3.60 17.00 0.00 17.00 4.72
11 2.00 19.10 52.00 6.12 58.12 3.04
12 1.00 4.07 18.00 4.36 22.36 5.49
13 1.00 14.30 39.00 0.00 39.00 2.73
14 1.00 3.96 14.50 4.58 19.08 4.82
15 1.00 0.76 4.50 0.00 4.50 5.92
16 2.00 0.64 5.00 2.20 7.20 11.25
17 4.00 3.00 12.00 0.00 12.00 4.00
18 3.00 10.74 32.50 0.00 32.50 3.03
19 5.00 2.01 9.00 0.00 9.00 4.48
20 2.00 3.45 12.00 0.00 12.00 3.48
21 1.00 3.79 17.00 0.00 17.00 4.49
22 1.00 17.20 52.00 6.12 58.12 3.38
23 1.00 3.10 11.00 0.00 11.00 3.55
24 3.00 2.85 10.50 0.00 10.50 3.68
25 3.00 1.30 7.50 0.00 7.50 5.77
26 1.00 11.41 32.00 5.76 37.76 3.31
27 1.00 4.60 15.00 5.76 20.76 4.51
28 2.00 6.75 23.00 0.00 23.00 3.41
29 1.00 3.84 15.00 0.00 15.00 3.91
30 6.00 1.64 9.50 0.00 9.50 5.79
31 1.00 16.08 44.50 0.00 44.50 2.77
32 2.00 7.40 24.50 6.12 30.62 4.14
33 5.00 1.70 8.00 0.00 8.00 4.71
34 0.00 3.60 17.00 0.00 17.00 4.72
35 2.00 19.10 52.00 6.12 58.12 3.04
36 1.00 4.07 18.00 4.36 22.36 5.49
37 1.00 14.30 39.00 0.00 39.00 2.73
38 1.00 3.96 14.50 4.58 19.08 4.82
39 1.00 0.76 4.50 0.00 4.50 5.92
40 2.00 0.64 5.00 2.20 7.20 11.25
41 4.00 3.00 12.00 0.00 12.00 4.00
42 3.00 10.74 32.50 0.00 32.50 3.03
43 5.00 2.01 9.00 0.00 9.00 4.48
44 2.00 3.45 12.00 0.00 12.00 3.48
45 1.00 3.79 17.00 0.00 17.00 4.49
46 1.00 17.20 52.00 6.12 58.12 3.38
47 1.00 3.10 11.00 0.00 11.00 3.55
48 3.00 2.85 10.50 0.00 10.50 3.68
Total Trips Made: 48.00
Trips With Tolls: 16.00
Toll Percentage: 33.33%
Total Passengers Carried: 100.00
Total Fares Paid: $1052.04
Total Distance Traveled: 294.58 mi
Average Distance Per Trip: 6.14 mi
Average Fare Per Trip: $21.92
Average Fare Per Person: $10.52
Average Fare Per Mile: $3.57
|