(1) of AQ have 2 private member variables: the primary pollutants (pri, string), air quality index (AQI, integer),
(2) construction method has two parameters, respectively, for the member variable pri, AQI initialization,
(3) members method int geAQI (), return to AQI index,
(4) members method String getGrd (), according to the AQI index return air quality levels,
AQI 0 to 50 51-100, 101-150, 151-200 201-300 & gt; 300
Air quality levels optimal benign and mild moderate pollution severe pollution serious pollution
(5) write a public static void main (String [] args) method, in order to enter a place for 300 days of air quality data (primary pollutants and air quality index), statistical output air quality for the most serious pollution of the consecutive days, and in turn output these days of main pollutants,
CodePudding user response:
Manually enter 300 days? Draw people brain is broken?