Answered step by step
Verified Expert Solution
Link Copied!

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
image text in transcribed
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

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Oracle PL/SQL Programming Database Management Systems

Authors: Steven Feuerstein

1st Edition

978-1565921429

Students also viewed these Databases questions

Question

How would you describe your typical day at work?

Answered: 1 week ago

Question

2. Write two or three of your greatest weaknesses.

Answered: 1 week ago