0
How i get a 'max rainfall day' using my code.👇👇👇
2 odpowiedzi
0
Hi there. A few comments for you:
1) What do you mean by max rainfall day? Haven't you already done it in your code? If you mean why you are unable to test it check two things: a) are you using floats as your input? and b) for some reason I can't test your code on mobile cos the input field is simply not large enough
2) Actually, the second for loop is redundant. while you are taking in the inputs and storing them into the array, you could have at the same time checked for the max value so that the program executes faster (marginally) since the constant C in the big O notation would be smaller in this case
3) If what I mentioned in 1) is not the answer to your question, feel free to let me know if you need further help :)
0
ජ්ය්ර්හිට්ග්නිජ්ග්