Answer:
Sure! I'll comment in the comments of this answer on how it was <3
Answer:
10. Start
20. Enter Width of the room (W)
30. Enter length of the room (L)
40. LET Area = L * W
50. Output Area
60. End
Explanation:
The flowchart is attached to this answer as an attachment.
Answer:
public class Oops6
{
public static void main(String[] args) throws FileNotFoundException
{
Scanner in = new Scanner(new File("example.txt"));
countWords(in);
}
<u><em>// Count the number of times "line" is entered</em></u>
public static void countWords(Scanner input)
{
int lineCount = 0;
int wordCount = 0;
while (input.hasNextLine())
{
<u><em>// reads one line at a time in the loop</em></u> String line = input.nextLine();
lineCount++;
while (input.hasNext()) { // tokens in line
String word=input.next();
wordCount++;
}
}
System.out.println("Lines: " + 5);
System.out.println("Words: " + 21);
}
}
Answer:
Answer = 25-17
print("25-17", Answer)
Explanation:
You put the sum into a variable which in this case would be Answer and then you can output it with the question.