NowComment
Document: Invite Print Info
2-Pane Combined
Comments:
Full Summaries Sorted

CSA 112

/***************************************** * Sample solution for Activity 1.1.2

*****************************************/

public class Allowance

{

public static void main(String[] args)

{

final double ALLOWANCE = 8.75;

int age = 16;

boolean isOldEnough = true;

System.out.print("Gina’s age is ");

System.out.println(age);

System.out.print("Eligible for allowance? ");

System.out.println(isOldEnough);

System.out.print("Gina’s weekly allowance is ");

System.out.println(ALLOWANCE);

age = 13; isOldEnough = true;

System.out.print("\nCarl’s age is ");

System.out.println(age);

System.out.print("Eligible for allowance? ");

System.out.println(isOldEnough);

System.out.print("Carl’s weekly allowance is ");

System.out.println(ALLOWANCE);

age = 3;

isOldEnough = false;

System.out.print("\nJennifer’s age is ");

System.out.println(age);

System.out.print("Eligible for allowance? ");

System.out.println(isOldEnough);

System.out.print("Jennifer does not get allowance");

}

}

DMU Timestamp: August 14, 2020 20:51





Image
0 comments, 0 areas
add area
add comment
change display
Video
add comment

Quickstart: Commenting and Sharing

How to Comment
  • Click icons on the left to see existing comments.
  • Desktop/Laptop: double-click any text, highlight a section of an image, or add a comment while a video is playing to start a new conversation.
    Tablet/Phone: single click then click on the "Start One" link (look right or below).
  • Click "Reply" on a comment to join the conversation.
How to Share Documents
  1. "Upload" a new document.
  2. "Invite" others to it.

Logging in, please wait... Blue_on_grey_spinner