Answered step by step
Verified Expert Solution
Question
1 Approved Answer
introduce yourself learnybooks.com in or Sign Up | Chegg.com zyBooks My library > CMP 167: Programming Methods i home > W 1.4 Comments and whitespace
introduce yourself
learnybooks.com in or Sign Up | Chegg.com zyBooks My library > CMP 167: Programming Methods i home > W 1.4 Comments and whitespace Help/FAQ Comments A comment is text a programmer adds to code, to be read by humans to better understand the code but ignored by the compler. Two common kinds of comments exist: A single-line comment starts with / and includes all the following text on that line Single-line comments commonly appear afte statement on the same line. A multi-line comment starts with and ends with where all text between and is part of the comment. A multi-line com also known as a block comment Figure 1.4.1: Comments example. import java.util.Scanner This programs calculates the amount of paxta to cook, given the mber of people eating. Date: May 10, 2017 public class Pantacalculator publie static void main(String targa Seaner Be Seat Syutini int napeople: 7 Number of people that will be sati int total ounces Pasta Total ounces of Dat e n Cet nuber of people System.out.printlnt inter wamber of people U eople-SORE. Int () * Caleulate and print total Ounces of pasta totalounces Pasta - People - Typical ounces per person System.out.println("Cook + totalOunces pasta t es of pasta Feedback? MacBook Pro 9 learnybooks.com in or Sign Up | Chegg.com zyBooks My library > CMP 167: Programming Methods i home > W 1.4 Comments and whitespace Help/FAQ Comments A comment is text a programmer adds to code, to be read by humans to better understand the code but ignored by the compler. Two common kinds of comments exist: A single-line comment starts with / and includes all the following text on that line Single-line comments commonly appear afte statement on the same line. A multi-line comment starts with and ends with where all text between and is part of the comment. A multi-line com also known as a block comment Figure 1.4.1: Comments example. import java.util.Scanner This programs calculates the amount of paxta to cook, given the mber of people eating. Date: May 10, 2017 public class Pantacalculator publie static void main(String targa Seaner Be Seat Syutini int napeople: 7 Number of people that will be sati int total ounces Pasta Total ounces of Dat e n Cet nuber of people System.out.printlnt inter wamber of people U eople-SORE. Int () * Caleulate and print total Ounces of pasta totalounces Pasta - People - Typical ounces per person System.out.println("Cook + totalOunces pasta t es of pasta Feedback? MacBook Pro 9 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