Before building a new power plant, a utility company must gain permission and procure the required permits for construction from the Environmental Protection Agency (EPA). At this time, the policy of the EPA is to limit construction of power plants to clean burning natural gas systems (to reduce emissions of CO2). One result of this policy is the reluctance of utility companies to build new power plants. California has recently experienced serious problems with their ability to provide enough electricity for its residents because of this reason. A result of this problem is that utility rates in California jumped 500% to 600% in a one-year period. With the above information in mind, and based on what you have read and discussed so far in class, discuss the pros and cons of this EPA policy. Be sure to keep in mind things like environmental impacts but also issues relating to social impacts due to higher electrical prices. While you are not required to review or search for additional information on the internet, please feel free to do so.
1.Starting with this provided code, add the following functionality: Replace hardcoded strings “Zero”, “One”, “Two”, “Three” in the ArrayList based on user typed input (use Scanner or JOptionPane classes). The user will be prompted for the String to be stored in the ArrayList and then hit enter. The user will be able to continue to add items to the ArrayList until they just hit enter without typing anything. Once the user does this (hits enter without typing anything), the program will display all of the elements of the ArrayList, both the index and String values, in a table. It will do this via a single loop making use of an iterator method. 2. Starting with this provided code, add the following functionality: Use a Try/Catch block so that the exception is caught and the program exits a bit more gracefully. Save this file as TryCatch.java. (Be sure to rename the Public Class accordingly.) Starting with the provided code again (without the Try/Catch block), fix the code so that ...

Comments
Post a Comment