Question
Overview: In Module Five, you have studied how to code for iteration through the use of loops. In Stepping Stone Lab Four, you will develop
Overview: In Module Five, you have studied how to code for iteration through the use of loops. In Stepping Stone Lab Four, you will develop a simple program with a loop structure for users to enter a list of ingredients. Be sure to review the Stepping Stone Lab Four guidelines before beginning this lab. The completed code (.java file) from Stepping Stone Lab Three is included in this module to use as a reference for comparison of your work in Module Four as well as moving forward. This code serves a number of functions: ? It allows you to review your own submitted code. ? You may utilize it as a useful foundation for Stepping Stone Lab Three as well as other assignments to come. ? Together with instructor feedback on your submitted code, you are building your own final project application. The code for this stepping stone lab is short, but the concepts are extremely important. You will use two different looping techniques: a do loop and a for loop. This stepping stone lab also includes your first application of the Java ArrayList data type. In this stepping stone lab, you will use the ArrayList to store strings, but in future submissions, you will replace these with object types (ingredients). Prompt: In this lab, you will write a short Java application that uses a loop control structure. Specifically, your application should accomplish the following: ? Create an ArrayList
package SteppingStones;
/* * To change this license header, choose License Headers in Project Properties. * To change this template file, choose Tools | Templates * and open the template in the editor. */ import java.util.Scanner; import java.util.ArrayList;
/** * * @author snhu.edu */ public class SteppingStone4_Loops { public static void main(String[] args) { Scanner scnr = new Scanner(System.in); String recipeName = ""; ArrayList
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started