Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Assignment 4 There are two tasks for this assignment. Task 1 : Please comment on the corresponding parts in the ATypicalJavaProgram.java used in the class.
Assignment
There are two tasks for this assignment.
Task : Please comment on the corresponding parts in the ATypicalJavaProgram.java used in the class. The ATypicalJavaProgram.java can be found in the moodle attached.
In the class, Weifeng Pan discussed the anatomy of a Java program by providing comments on key sections of the code. Follow Weifeng Pan's example by commenting and modifying the code yourself. Completing this task will give you a better understanding of what a standard Java program should resemble.
Please submit the commented version to Moodle.
Task : Thinking, reasoning, and fixing
For details, please refer to the comments in the IdentifiersDemo.java.
Please submit the commented version to Moodle.
Warning: All the materials should be compressed into one file and submitted to Moodle.
package edu.outypicaljavaprogram;
interface IWalk
void walk;
class Animal
public void sayString content
System.out.printlnAnimals say
content ;
class Dog extends Animal implements IWalk
private String name "Wang";
@override
public void sayString content
System.out.printlnDogs name
say content ;
@Override
public void walk
System.out.printlnDogs walk...";
public class ATypicalJavaProgram
public static void mainString args
Dog dog new Dog;
dog.sayI am cute.";
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