Author | Message |
---|---|
ed12al
Posts: 5
|
Posted 17:40 Jan 17, 2015 |
The instruction said that our program must be able to work for an array of any size. Does it mean we have to make our program works for size of 1, too? For method 06 (find the second largest number), If the array = {1, 2, 3, 3}; which number should we print out? 2 or 3? Last edited by ed12al at
17:49 Jan 17, 2015.
|
kknaur
Posts: 540
|
Posted 18:48 Jan 17, 2015 |
By any size I really mean a larger size. So, for simplicity sake make sure your array works for at least sizes >= 2 if size of 1 is an issue. |
ed12al
Posts: 5
|
Posted 18:59 Jan 17, 2015 |
how about for method06? Find the second largest number If the array = {1 , 2, 3, 3} Which number should we print out? 2 or 3?
|
rkmx52
Posts: 23
|
Posted 20:08 Jan 17, 2015 |
2 |
raywu64
Posts: 44
|
Posted 09:05 Jan 18, 2015 |
Did you email Keenan about this? To me, logically, it would be 3. |
raywu64
Posts: 44
|
Posted 09:19 Jan 18, 2015 |
Nevermind, I retract. After some thought, I think it's more logical if it's two. |