Data Structures 5/13


Stuck at exercise 5/13. Link :

My code displays the output of 67, which is the lowest temperature in the arraylist, but the error keeps coming up “did you print the lowest temperature?”

The exercise does not let me move on but Im sure my code is correct.

import java.util.ArrayList;

public class Temperatures {
	public static void main(String[] args) {
/*create arraylist object weeklyTemperatrues of class type Integer(whole number)
ArrayList<Integer> weeklyTemperatures = new ArrayList<Integer>();
    /*adding integers 78, 67, 89, 94 to the arraylist. calling method add on arraylist object weeklyTemperatures
    //using get method to print lowest temp in weeklyTemperatrues




This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.