#Write a program in java to demonstrate Default constructor?
Explore tagged Tumblr posts
subb01 · 7 months ago
Text
Top Java Interview Questions You Should Know
Preparing for a Java interview can be daunting, especially when you're unsure of what to expect. Mastering common Java questions is crucial for making a lasting impression. This blog covers the top Java interview questions you should know and provides tips for answering them effectively. For a more interactive learning experience, check out this Java interview preparation video, which breaks down key concepts and interview strategies.
1. What is Java?
Answer: Java is a high-level, object-oriented programming language developed by Sun Microsystems (now owned by Oracle). It is designed to have as few implementation dependencies as possible, allowing developers to write code that runs on all platforms supporting Java without the need for recompilation.
Pro Tip: Mention the "write once, run anywhere" (WORA) principle during your interview to emphasize your understanding of Java’s cross-platform capabilities.
2. What is the Difference Between JDK, JRE, and JVM?
Answer:
JDK (Java Development Kit): Contains tools for developing Java applications, including the JRE and compilers.
JRE (Java Runtime Environment): A subset of JDK, containing libraries and components required to run Java applications.
JVM (Java Virtual Machine): The part of the JRE responsible for executing Java bytecode on different platforms.
Pro Tip: Explain how these components interact to demonstrate a deeper understanding of Java's execution process.
3. Explain OOP Principles in Java
Answer: Java is based on four main principles of Object-Oriented Programming (OOP):
Encapsulation: Bundling data and methods that operate on the data within one unit (class).
Inheritance: Creating a new class from an existing class to promote code reuse.
Polymorphism: The ability of a method or function to behave differently based on the object calling it.
Abstraction: Hiding complex implementation details and showing only the necessary features.
Pro Tip: Use a real-world example to illustrate these principles for better impact.
4. What are Constructors in Java?
Answer: Constructors are special methods used to initialize objects in Java. They have the same name as the class and do not have a return type. There are two types:
Default Constructor: Automatically created if no other constructors are defined.
Parameterized Constructor: Accepts arguments to initialize an object with specific values.
Pro Tip: Highlight the differences between constructors and regular methods, and explain constructor overloading.
5. What is the Difference Between == and .equals() in Java?
Answer:
==: Used to compare primitive data types or check if two object references point to the same memory location.
.equals(): Used to compare the content within objects. This method should be overridden for custom comparison logic in classes.
Pro Tip: Demonstrating this concept with code snippets can be a game-changer in your interview.
6. What are Java Collections?
Answer: The Java Collections Framework (JCF) provides a set of classes and interfaces to handle collections of objects. Commonly used collections include:
List (e.g., ArrayList, LinkedList)
Set (e.g., HashSet, TreeSet)
Map (e.g., HashMap, TreeMap)
Pro Tip: Be prepared to discuss the performance differences between various collections and when to use each.
7. What is Exception Handling in Java?
Answer: Exception handling in Java involves managing runtime errors to maintain normal program flow. The main keywords used are:
try: Block to wrap code that might throw an exception.
catch: Block to handle the exception.
finally: Block that always executes, used for cleanup code.
throw and throws: Used to manually throw an exception and indicate that a method may throw an exception, respectively.
Pro Tip: Discuss custom exceptions and when it is appropriate to create them for better code design.
8. What is Multithreading in Java?
Answer: Multithreading is a feature in Java that allows concurrent execution of two or more threads. It is useful for performing multiple tasks simultaneously within a program.
Pro Tip: Familiarize yourself with the Thread class and Runnable interface. Highlight synchronization and thread-safe practices to show advanced understanding.
9. What are Lambda Expressions in Java?
Answer: Introduced in Java 8, lambda expressions provide a concise way to implement functional interfaces. They enable writing cleaner, more readable code for single-method interfaces (e.g., using a lambda to sort a list).
Example:
java
Copy code
List<String> list = Arrays.asList("apple", "banana", "cherry");
list.sort((a, b) -> a.compareTo(b));
Pro Tip: Mention how lambda expressions contribute to functional programming in Java.
10. What is the Significance of the final Keyword?
Answer: The final keyword can be used with variables, methods, and classes to restrict their usage:
Variables: Makes the variable constant.
Methods: Prevents method overriding.
Classes: Prevents inheritance.
Pro Tip: Explain how using final can improve security and design integrity in your applications.
Conclusion
Reviewing these questions and understanding their answers can prepare you for technical interviews. For additional explanations and examples, check out this detailed Java interview preparation video.
youtube
0 notes
ittimepass · 8 years ago
Text
Write a program in java to demonstrate Default constructor?
class DefaultConstructor {                 int a,b;                 public void display()                 {                                 System.out.println(a);                                 System.out.println(b);                 }                 public static void main(String arg[])                 {                                 DefaultConstructor x=new DefaultConstructor();…
View On WordPress
0 notes
siva3155 · 6 years ago
Text
300+ TOP SCALA Interview Questions and Answers
SCALA Interview Questions for freshers experienced :-
1. What is Scala? Scala is a Java-based Hybrid programming language which is the fusion of both Functional and Object-Oriented Programming Language features. It can integrate itself with Java Virtual Machine and compile the code written. 2. How Scala is both Functional and Object-oriented Programming Language? Scala treats every single value as an Object which even includes Functions. Hence, Scala is the fusion of both Object-oriented and Functional programming features. 3.Write a few Frameworks of Scala Some of the Frameworks supported by Scala are as follows: Akka Framework Spark Framework Play Framework Scalding Framework Neo4j Framework Lift Framework Bowler Framework 4. Explain the types of Variables in Scala? And What is the difference between them? The Variables in Scala are mainly of two types: Mutable Variables We Declare Mutable Variables by using the var keyword. The values in the Mutable Variables support Changes Immutable Variables We declare Immutable Variables using the val keyword. The values in Immutable Variables do not support changes. 5. Explain Streams in Scala. In simple words, we define Stream as a Lazy list which evaluates the elements only when it needs to. This sort of lazy computation enhances the Performance of the program. 6. Mention the Advantages of Scala Some of the major Advantages of Scala are as follows: It is highly Scalable It is highly Testable It is highly Maintainable and Productive It facilitates Concurrent programming It is both Object-Oriented and Functional It has no Boilerplate code Singleton objects are a cleaner solution than Static Scala Arrays use regular Generics Scala has Native Tuples and Concise code 7. Explain the Operators in Scala The following are the Operators in Scala: Arithmetic Operators Relational Operators Logical Operators Bitwise Operators Assignment Operators 8. What is Recursion tail in Scala? ‘Recursion’ is a function that calls itself. For example, a function ‘A’ calls function ‘B’, which calls the function ‘C’. It is a technique used frequently in Functional programming. In order for a Tail recursive, the call back to the function must be the last function to be performed. 9. Explain the use of Tuples in Scala? Scala tuples combine a Finite number of items together so that the programmer can Pass a tuple around as a Whole. Unlike an Array or List, a tuple is Immutable and can hold objects with different Datatypes. 10. How is a Class different from an Object? Class combines the data and its methods whereas an Object is one particular Instance in a class.
Tumblr media
SCALA Interview Questions 11. Why do we need App in Scala? App is a helper class that holds the main method and its Members together. The App trait can be used to quickly turn Objects into Executable programs. We can have our classes extend App to render the executable code. object Edureka extends App{ println("Hello World") } 12. What are Higher-order functions? A Higher-order function is a function that does at least one of the following: takes one or more Functions as Arguments, returns a Function as its result. 13. Explain the scope provided for variables in Scala. There are three different scopes depending upon their use. Namely: Fields: Fields are variables declared inside an object and they can be accessed anywhere inside the program depending upon the access modifiers. Fields can be declared using var as well as val. Method Parameters: Method parameters are strictly Immutable. Method parameters are mainly used to Pass values to the methods. These are accessed inside a method, but it is possible to access them from outside the method provided by a Reference. Local Variables: Local variables are declared inside a method and they are accessible only inside the method. They can be accessed if you return them from the method. 14. What is a Closure? Closure is considered as a Function whose return value is Dependent upon the value of one or more variables declared outside the closure function. Course Curriculum Apache Spark and Scala Certification Training Instructor-led SessionsReal-life Case StudiesAssessmentsLifetime Access Example: val multiplier = (i:Int) => i * 10 Here the only variable used in the function body, i * 10 , is i, which is defined as a parameter to the function 15. Explain Traits in Scala. A Trait can be defined as a unit which Encapsulates the method and its variables or fields. The following example will help us understand in a better way. trait Printable{ def print() } class A4 extends Printable{ def print(){ println("Hello") } } object MainObject{ def main(args:Array){ var a = new A4() a.print() } } 16. Mention how Scala is different from Java A few scenarios where Scala differs from Java are as follows: All values are treated as Objects. Scala supports Closures Scala Supports Concurrency. It has Type-Inference. Scala can support Nested functions. It has DSL support Traits 17. Explain extend Keyword You can extend a base Scala class and you can design an Inherited class in the same way you do it in Java by using extends keyword, but there are two restrictions: method Overriding requires the override keyword, and only the Primary constructor can pass parameters to the base Constructor. Let us understand by the following example println("How to extend abstract class Parent and define a sub-class of Parent called Child") class Child=(name:String)extends Parent(name){ override def printName:Unit= println(name) } object Child { def apply(name:String):Parent={ new Child(name) } } 18. Explain implicit classes with syntax Implicit classes allow Implicit conversations with the class’s Primary constructor when the class is in scope. Implicit class is a class marked with the “implicit” keyword. This feature was introduced in with Scala 2.10 version. //Syntax: object { implicit class Data type) { def Unit = xyz } } 19. Explain the access Modifiers available in Scala There are mainly three access Modifiers available in Scala. Namely, Private: The Accessibility of a private member is restricted to the Class or the Object in which it declared. The following program will explain this in detail. class Outer { class Inner { private def f() { println("f") } class InnerMost { f() // OK } } (new Inner).f() // Error: f is not accessible } Protected: A protected member is only Accessible from Subclasses of the class in which the member is defined. The following program will explain this in detail. package p class Super { protected def f() { println("f") } } class Sub extends Super { f() } class Other { (new Super).f() // Error: f is not accessible } } Public: Unlike Private and Protected members, it is not required to specify Public keyword for Public members. There is no explicit modifier for public members. Such members can be accessed from Anywhere. Following is the example code snippet to explain Public member class Outer { class Inner { def f() { println("f") } class InnerMost { f() // OK } } (new Inner).f() // OK because now f() is public } 20. What is a Monad in Scala? A Monad is an object that wraps another object. You pass the Monad mini-programs, i.e functions, to perform the data manipulation of the underlying object, instead of manipulating the object directly. Monad chooses how to apply the program to the underlying object. 21. Explain the Scala Anonymous Function. In the Source code, Anonymous functions are called ‘Function literals’ and at run time, function literals are instantiated into objects called Function values. Scala provides a relatively easy Syntax for defining Anonymous functions. //Syntax (z:Int, y:Int)=> z*y Or (_:Int)*(_Int) 22. How do I Append data in a list? In Scala to Append into a List, We have the following methods: use “:+” single value var myList = List.empty myList :+= "a" 23. Why Scala prefers Immutability? Scala prefers Immutability in design and in many cases uses it as default. Immutability can help when dealing with Equality issues or Concurrent programs. 24. Give some examples of Packages in Scala The three important and default Packages in Scala are as follows: Java.lang._ : Java.lang._ package in Java. Provides classes that are fundamental to the design of the Java programming language. Java.io._ : Java.io._ Package used to import every class in Scala for input-output resources. PreDef: Predef provides type aliases for types which are commonly used, such as the immutable collection types Map, Set, and the List constructors 25. Why is an Option used in Scala? Option in Scala is used to Wrap the Missing value. 26. Mention the Identifiers in Scala. There are four types of Scala Identifiers: Alphanumeric identifiers Operator identifiers Mixed identifiers Literal identifiers //Scala program to demonstrate Identifiers in Scala. object Main { //Main method def main(args: Array) { //Valid Identifiers var 'name = "Hari"' var age = 20; var Branch = "Computer Science" println() println() println() } } 27. How do you define a function in Scala? def keyword is used to define the Function in Scala. object add { def addInt( a:Int, b:Int ) : Int = { var sum:Int = 0 sum = a + b return sum } } 28. How is the Scala code compiled? Code is written in Scala IDE or a Scala REPL, Later, the code is converted into a Byte code and transferred to the JVM or Java Virtual Machine for compilation. Big Data Training 29. Explain the functionality of Yield. Yield is used with a loop, Yield produces a value for each iteration. Another way to do is to use map/flatMap and filter with nomads. for (i "#FF0000", "azure" -> "#F0FFFF") 39. Explain Exception Handling in Scala Throw Exception: Throwing an exception looks the same as in Java. You create an exception object and then you throw it with the throw keyword as follows. Throw new IllegalArgumentException Catching an Exception: Scala allows you to try/catch any exception in a single block and then perform pattern matching against it using case blocks. Try the following example program to handle the exception. Example: import java.io.FileReader import java.io.FileNotFoundException import java.io.IOException object Demo { def main(args: Array) { try { val f = new FileReader("input.txt") } catch { case ex: FileNotFoundException ={ println("Missing file exception") } case ex: IOException = { println("IO Exception") } } } } So, with this, we finished some questions on the Intermediate Level. Now, Let us move to the next level of interview questions which happen to be the Advanced Level Interview Questions. 40. Explain Pattern Matching in Scala through an example A Pattern match includes a sequence of alternatives, each starting with the Keyword case. Each alternative includes a Pattern and one or more Expressions, Scala evaluates whenever a pattern matches. An arrow symbol => separates the pattern from the expressions. Try the following example program, which shows how to match against an integer value. object Demo { def main(args: Array) { println(matchTest(3)) } def matchTest(x: Int): String = x match { case 1 = "one" case 2 = "two" case _ = "other" } } 41. Explain Extractors in Scala Course Curriculum Apache Spark and Scala Certification Training Weekday / Weekend Batches An Extractor in Scala is an object that has a method called unapply as one of its members. The purpose of that unapply method is to match the value and take it apart. 42. What is the result of x+y*z and why? Similar to any other programming language, Scala also follows Presidency and Priority tables. According to the tables, Scala Performs the operations as follows. Scala evaluates y*z first. Then adds (y*z) with x 43. What is an Auxiliary constructor We use Auxiliary constructor in Scala for Constructor Overloading. The Auxiliary Constructor must call either previously defined auxiliary constructors or primary constructor in the first line of its body. 44. Explain recursion through a program def factorial_loop(i: BigInt): BigInt = { var result = BigInt(1) for (j- 2 to i.intValue) result *= j result } for (i - 1 to 10) format("%s: %sn", i, factorial_loop(i)) 45. Explain Que with example Queue is a Data Structure similar to Stack except, it follows First In First Out procedure for data processing. In Scala, to work with Queues, you need to import a library called, import scala.collection.mutable.Queue val empty = new Queue SCALA Questions and Answers Pdf Download Read the full article
0 notes
assignmentsolutions4me · 7 years ago
Text
ITC538 | Designing Object Oriented Program | Java
Task
Assessment 2 has 20 marks in total. Marks will be scaled according to the value of the assessment.
There are two tasks in assessment 2, Task 1 and Task 2 as below:
Task 1: Value 10 marks
Suppose you are commissioned by the Australian Football Association (AFL) to write a program designed to produce statistics based on complete scores recorded in a season. These scores are kept in a file called afl.txt (available on interact resources). You are also given the following information about a football season:
League consists of 18 football teams
There are 22 rounds in each season
In each round teams play against each other and the score of each team is recorded as an integer and kept in the text file referred to above (aft.txt)
Your task is to write a complete java program (a java class with the main method) called ProcessScores, which will read the scores from the text file provided, store the scores in an array of integers and then using a number of independent static methods, calculate and display the required statistics relating the afl scores.
The java class you are required to author will contain the following static methods:
lowest will take the array of scores as an argument and return the lowest score in the season highest will take the array of scores as an argument and return the highest score in the season
range will take the array of scores as an argument and return the difference between the highest score and the lowest score in the season
average will take the array of scores as an argument and return the average of all scores in the season
median will take the array of scores as an argument and return the median score in the season
mode will take the array of scores as an argument and return the mode of the scores in the season
Note that all of the methods described above, should be static methods; user defined methods (you have the write the definition of each yourself); and completely independent of each other (you should not invoke anyone of them within the other method definition). Also, the original array of scores should not be modified by any of the methods.
Ensure that the program is appropriately documented throughout and thoroughly tested to demonstrate its correct operation.
You need to submit java and class files, a short discussion to explain the logic on how the problem has been solved, and sample output (for detail please see marking guide and presentation below).
Task 2: Value 10 marks
Design a class named Light to represent a conference hall light. The class contains:
Three constants named LOW, MEDIUM, and HIGH with the values 1, 2, and 3 to denote Charles Sturt University Subject Outline the light brightness.
A private int data field named brightness that specifies the brightness of the light having a default value of LOW.
A private boolean data field named on that specifies whether the light is on or off having a default value of false.
A string data field named color that specifies the color of the light having a default value of red.
The accessor and mutator methods for all three data fields.
A no-arg/default constructor that creates a default light.
A method named toString() that returns a string description for the light. If the light is on, the method returns the fan brightness and color in one combined string. If the light is not on, the method returns the fan color along with the string “light is off” in one combined string. Draw the UML diagram for the class and then implement the class.
Write a test program TestLight that creates two Light objects. Assign high brightness, color yellow, and turn it on to the first object. Assign medium brightness, color blue, and turn it off to the second object. Display the objects by invoking their respective toString methods.
Ensure that the program is appropriately documented throughout and thoroughly tested to demonstrate its correct operation.
You need to submit java and class files, a short discussion to explain the logic on how the problem has been solved, UML diagram, and sample output (for detail please see marking guide and presentation below).
Rationale
This assignment has been designed to allow students to test and demonstrate their ability to:
design and implement algorithms in Java (learning outcome 1);
interpret and evaluate design requirements expressed in Unified Modelling Language (UML) (learning outcome 2);
use object-oriented techniques and Java resources to develop small applications consisting of a number of classes (learning outcome 4);
apply testing and debugging techniques in program development (learning outcome 5);
Order Now
0 notes
valeriegwavuya444-blog · 7 years ago
Photo
Tumblr media
New Post has been published on https://punjabassignmenthelp.com/itc538-designing-object-oriented-program/
ITC538 | DESIGNING OBJECT ORIENTED PROGRAM
ITC538 | DESIGNING OBJECT ORIENTED PROGRAM | JAVA
JAVA ASSIGNMENT HELP
Task
Assessment 2 has 20 marks in total. Marks will be scaled according to the value of the assessment.
There are two tasks in assessment 2, Task 1 and Task 2 as below:
Task 1: Value 10 marks
Suppose you are commissioned by the Australian Football Association (AFL) to write a program designed to produce statistics based on complete scores recorded in a season. These scores are kept in a file called afl.txt (available on interact resources). You are also given the following information about a football season:
League consists of 18 football teams
There are 22 rounds in each season
In each round teams play against each other and the score of each team is recorded as an integer and kept in the text file referred to above (aft.txt)
Your task is to write a complete java program (a java class with the main method) called ProcessScores, which will read the scores from the text file provided, store the scores in an array of integers and then using a number of independent staticmethods, calculate and display the required statistics relating the afl scores.
The java class you are required to author will contain the following static methods:
lowest will take the array of scores as an argument and return the lowest score in the season highest will take the array of scores as an argument and return the highest score in the season
range will take the array of scores as an argument and return the difference between the highest score and the lowest score in the season
average will take the array of scores as an argument and return the average of all scores in the season
median will take the array of scores as an argument and return the median score in the season
mode will take the array of scores as an argument and return the mode of the scores in the season
Note that all of the methods described above, should be static methods; user defined methods (you have the write the definition of each yourself); and completely independent of each other (you should not invoke anyone of them within the other method definition). Also, the original array of scores should not be modified by any of the methods.
Ensure that the program is appropriately documented throughout and thoroughly tested to demonstrate its correct operation.
You need to submit java and class files, a short discussion to explain the logic on how the problem has been solved, and sample output (for detail please see marking guide and presentation below).
Task 2: Value 10 marks
Design a class named Light to represent a conference hall light. The class contains:
Three constants named LOW, MEDIUM, and HIGH with the values 1, 2, and 3 to denote Charles Sturt University Subject Outline the light brightness.
A private int data field named brightness that specifies the brightness of the light having a default value of LOW.
A private boolean data field named on that specifies whether the light is on or off having a default value of false.
A string data field named color that specifies the color of the light having a default value of red.
The accessor and mutator methods for all three data fields.
A no-arg/default constructor that creates a default light.
A method named toString() that returns a string description for the light. If the light is on, the method returns the fan brightness and color in one combined string. If the light is not on, the method returns the fan color along with the string “light is off” in one combined string. Draw the UML diagram for the class and then implement the class.
Write a test program TestLight that creates two Light objects. Assign high brightness, color yellow, and turn it on to the first object. Assign medium brightness, color blue, and turn it off to the second object. Display the objects by invoking their respective toString methods.
Ensure that the program is appropriately documented throughout and thoroughly tested to demonstrate its correct operation.
You need to submit java and class files, a short discussion to explain the logic on how the problem has been solved, UML diagram, and sample output (for detail please see marking guide and presentation below).
  Rationale
This assignment has been designed to allow students to test and demonstrate their ability to:
design and implement algorithms in Java (learning outcome 1);
interpret and evaluate design requirements expressed in Unified Modelling Language (UML) (learning outcome 2);
use object-oriented techniques and Java resources to develop small applications consisting of a number of classes (learning outcome 4);
apply testing and debugging techniques in program development (learning outcome 5);
Marking criteria
Assessment 2 (Total Marks 20)
Task 1 (Total Marks 10)
Criteria Marks HD DI   CR PS     Program                     a. Execution: Program   executes Provided java     Provided java   perfectly   Provided java launches, executes and   program executes   program may be   without   program executes terminates without 1.0 without crashing   incomplete and/or crashing   without crashing crashing; program executes   with minimal   executes with   towards   with some errors as specified.   errors   some errors   intended                     output                      
  Implement Implement Implement Implement and integrate ProcessScores ProcessScores class ProcessScores classes with class with most of with majority of class with some all functions the functions and the functions and functions and
  Criteria Marks HD DI   CR PS              
  by integrate the mark integrate the mark then combine it maintaining class with it for class with it for with Marks class logical flow testing testing for testing Excellent       naming, Good naming, Most naming, Some naming, indentation, indentation, indentation, indentation, header header and header and inline and inline header and inline inline comments comments comments included comments included   included included      
        All of the Most of the   Just enough of the     required Majority of the d. Submission: the   required required   documents required documents documents with all   documents and documents and components (analysis, 1.0 and sufficient sufficient number and sufficient sufficient number testing, and output)   number of of test outputs number of test of test outputs   test outputs outputs provided     provided provided     provided            
Task 2 (Total Marks 10)
  Criteria Marks HD DI CR PS     Program Provided java     a. Execution: Program   executes   Provided java   program Provided java launches, executes and   perfectly program may be   executes program executes terminates without crashing; 1.0 without incomplete and/or without without crashing program executes as   crashing executes with   crashing with with some errors specified.   towards some errors   minimal errors       intended output    
    Implement and Implement and Implement Light Implement Light   integrate all of integrate most and TestLight and TestLight   of the Light and classes with classes with some 6.0 the Light and TestLight majority functions functions and   TestLight   classes and combine them combine them for   classes   functionaliies for testing testing       UML with all UML with most UML with UML with   components components and majority incomplete 1.0 and their their parameter, components and components and   parameter, and and return their parameter, their parameter,   return and return and return       All of the Most of the Majority of the Just enough of the   required required   required required   documents and documents and   documents and documents and 1.0 sufficient sufficient sufficient number sufficient number   number of test number of test   of test outputs of test outputs   outputs outputs   provided provided   provided provided         All of the Most of the Majority of the Just enough of the   required required   required required   documents and documents and   documents and documents and 1.0 sufficient sufficient sufficient number sufficient number   number of test number of test   of test outputs of test outputs   outputs outputs   provided provided   provided provided      
Punjab Assignment Help
Buy Online Assignment Help services for JAVA ASSIGNMENT with Punjab Assignment Help at [email protected]
0 notes
gillmahi9123-blog · 7 years ago
Photo
Tumblr media
New Post has been published on https://punjabassignmenthelp.com/itc538-designing-object-oriented-program/
ITC538 | DESIGNING OBJECT ORIENTED PROGRAM
ITC538 | DESIGNING OBJECT ORIENTED PROGRAM | JAVA
JAVA ASSIGNMENT HELP
Task
Assessment 2 has 20 marks in total. Marks will be scaled according to the value of the assessment.
There are two tasks in assessment 2, Task 1 and Task 2 as below:
Task 1: Value 10 marks
Suppose you are commissioned by the Australian Football Association (AFL) to write a program designed to produce statistics based on complete scores recorded in a season. These scores are kept in a file called afl.txt (available on interact resources). You are also given the following information about a football season:
League consists of 18 football teams
There are 22 rounds in each season
In each round teams play against each other and the score of each team is recorded as an integer and kept in the text file referred to above (aft.txt)
Your task is to write a complete java program (a java class with the main method) called ProcessScores, which will read the scores from the text file provided, store the scores in an array of integers and then using a number of independent staticmethods, calculate and display the required statistics relating the afl scores.
The java class you are required to author will contain the following static methods:
lowest will take the array of scores as an argument and return the lowest score in the season highest will take the array of scores as an argument and return the highest score in the season
range will take the array of scores as an argument and return the difference between the highest score and the lowest score in the season
average will take the array of scores as an argument and return the average of all scores in the season
median will take the array of scores as an argument and return the median score in the season
mode will take the array of scores as an argument and return the mode of the scores in the season
Note that all of the methods described above, should be static methods; user defined methods (you have the write the definition of each yourself); and completely independent of each other (you should not invoke anyone of them within the other method definition). Also, the original array of scores should not be modified by any of the methods.
Ensure that the program is appropriately documented throughout and thoroughly tested to demonstrate its correct operation.
You need to submit java and class files, a short discussion to explain the logic on how the problem has been solved, and sample output (for detail please see marking guide and presentation below).
Task 2: Value 10 marks
Design a class named Light to represent a conference hall light. The class contains:
Three constants named LOW, MEDIUM, and HIGH with the values 1, 2, and 3 to denote Charles Sturt University Subject Outline the light brightness.
A private int data field named brightness that specifies the brightness of the light having a default value of LOW.
A private boolean data field named on that specifies whether the light is on or off having a default value of false.
A string data field named color that specifies the color of the light having a default value of red.
The accessor and mutator methods for all three data fields.
A no-arg/default constructor that creates a default light.
A method named toString() that returns a string description for the light. If the light is on, the method returns the fan brightness and color in one combined string. If the light is not on, the method returns the fan color along with the string “light is off” in one combined string. Draw the UML diagram for the class and then implement the class.
Write a test program TestLight that creates two Light objects. Assign high brightness, color yellow, and turn it on to the first object. Assign medium brightness, color blue, and turn it off to the second object. Display the objects by invoking their respective toString methods.
Ensure that the program is appropriately documented throughout and thoroughly tested to demonstrate its correct operation.
You need to submit java and class files, a short discussion to explain the logic on how the problem has been solved, UML diagram, and sample output (for detail please see marking guide and presentation below).
  Rationale
This assignment has been designed to allow students to test and demonstrate their ability to:
design and implement algorithms in Java (learning outcome 1);
interpret and evaluate design requirements expressed in Unified Modelling Language (UML) (learning outcome 2);
use object-oriented techniques and Java resources to develop small applications consisting of a number of classes (learning outcome 4);
apply testing and debugging techniques in program development (learning outcome 5);
Marking criteria
Assessment 2 (Total Marks 20)
Task 1 (Total Marks 10)
Criteria Marks HD DI   CR PS     Program                     a. Execution: Program   executes Provided java     Provided java   perfectly   Provided java launches, executes and   program executes   program may be   without   program executes terminates without 1.0 without crashing   incomplete and/or crashing   without crashing crashing; program executes   with minimal   executes with   towards   with some errors as specified.   errors   some errors   intended                     output                      
  Implement Implement Implement Implement and integrate ProcessScores ProcessScores class ProcessScores classes with class with most of with majority of class with some all functions the functions and the functions and functions and
  Criteria Marks HD DI   CR PS              
  by integrate the mark integrate the mark then combine it maintaining class with it for class with it for with Marks class logical flow testing testing for testing Excellent       naming, Good naming, Most naming, Some naming, indentation, indentation, indentation, indentation, header header and header and inline and inline header and inline inline comments comments comments included comments included   included included      
        All of the Most of the   Just enough of the     required Majority of the d. Submission: the   required required   documents required documents documents with all   documents and documents and components (analysis, 1.0 and sufficient sufficient number and sufficient sufficient number testing, and output)   number of of test outputs number of test of test outputs   test outputs outputs provided     provided provided     provided            
Task 2 (Total Marks 10)
  Criteria Marks HD DI CR PS     Program Provided java     a. Execution: Program   executes   Provided java   program Provided java launches, executes and   perfectly program may be   executes program executes terminates without crashing; 1.0 without incomplete and/or without without crashing program executes as   crashing executes with   crashing with with some errors specified.   towards some errors   minimal errors       intended output    
    Implement and Implement and Implement Light Implement Light   integrate all of integrate most and TestLight and TestLight   of the Light and classes with classes with some 6.0 the Light and TestLight majority functions functions and   TestLight   classes and combine them combine them for   classes   functionaliies for testing testing       UML with all UML with most UML with UML with   components components and majority incomplete 1.0 and their their parameter, components and components and   parameter, and and return their parameter, their parameter,   return and return and return       All of the Most of the Majority of the Just enough of the   required required   required required   documents and documents and   documents and documents and 1.0 sufficient sufficient sufficient number sufficient number   number of test number of test   of test outputs of test outputs   outputs outputs   provided provided   provided provided         All of the Most of the Majority of the Just enough of the   required required   required required   documents and documents and   documents and documents and 1.0 sufficient sufficient sufficient number sufficient number   number of test number of test   of test outputs of test outputs   outputs outputs   provided provided   provided provided      
Punjab Assignment Help
Buy Online Assignment Help services for JAVA ASSIGNMENT with Punjab Assignment Help at [email protected]
0 notes
nuramukhtar64-blog · 7 years ago
Photo
Tumblr media
New Post has been published on https://punjabassignmenthelp.com/itc538-designing-object-oriented-program/
ITC538 | DESIGNING OBJECT ORIENTED PROGRAM
ITC538 | DESIGNING OBJECT ORIENTED PROGRAM | JAVA
JAVA ASSIGNMENT HELP
Task
Assessment 2 has 20 marks in total. Marks will be scaled according to the value of the assessment.
There are two tasks in assessment 2, Task 1 and Task 2 as below:
Task 1: Value 10 marks
Suppose you are commissioned by the Australian Football Association (AFL) to write a program designed to produce statistics based on complete scores recorded in a season. These scores are kept in a file called afl.txt (available on interact resources). You are also given the following information about a football season:
League consists of 18 football teams
There are 22 rounds in each season
In each round teams play against each other and the score of each team is recorded as an integer and kept in the text file referred to above (aft.txt)
Your task is to write a complete java program (a java class with the main method) called ProcessScores, which will read the scores from the text file provided, store the scores in an array of integers and then using a number of independent staticmethods, calculate and display the required statistics relating the afl scores.
The java class you are required to author will contain the following static methods:
lowest will take the array of scores as an argument and return the lowest score in the season highest will take the array of scores as an argument and return the highest score in the season
range will take the array of scores as an argument and return the difference between the highest score and the lowest score in the season
average will take the array of scores as an argument and return the average of all scores in the season
median will take the array of scores as an argument and return the median score in the season
mode will take the array of scores as an argument and return the mode of the scores in the season
Note that all of the methods described above, should be static methods; user defined methods (you have the write the definition of each yourself); and completely independent of each other (you should not invoke anyone of them within the other method definition). Also, the original array of scores should not be modified by any of the methods.
Ensure that the program is appropriately documented throughout and thoroughly tested to demonstrate its correct operation.
You need to submit java and class files, a short discussion to explain the logic on how the problem has been solved, and sample output (for detail please see marking guide and presentation below).
Task 2: Value 10 marks
Design a class named Light to represent a conference hall light. The class contains:
Three constants named LOW, MEDIUM, and HIGH with the values 1, 2, and 3 to denote Charles Sturt University Subject Outline the light brightness.
A private int data field named brightness that specifies the brightness of the light having a default value of LOW.
A private boolean data field named on that specifies whether the light is on or off having a default value of false.
A string data field named color that specifies the color of the light having a default value of red.
The accessor and mutator methods for all three data fields.
A no-arg/default constructor that creates a default light.
A method named toString() that returns a string description for the light. If the light is on, the method returns the fan brightness and color in one combined string. If the light is not on, the method returns the fan color along with the string “light is off” in one combined string. Draw the UML diagram for the class and then implement the class.
Write a test program TestLight that creates two Light objects. Assign high brightness, color yellow, and turn it on to the first object. Assign medium brightness, color blue, and turn it off to the second object. Display the objects by invoking their respective toString methods.
Ensure that the program is appropriately documented throughout and thoroughly tested to demonstrate its correct operation.
You need to submit java and class files, a short discussion to explain the logic on how the problem has been solved, UML diagram, and sample output (for detail please see marking guide and presentation below).
  Rationale
This assignment has been designed to allow students to test and demonstrate their ability to:
design and implement algorithms in Java (learning outcome 1);
interpret and evaluate design requirements expressed in Unified Modelling Language (UML) (learning outcome 2);
use object-oriented techniques and Java resources to develop small applications consisting of a number of classes (learning outcome 4);
apply testing and debugging techniques in program development (learning outcome 5);
Marking criteria
Assessment 2 (Total Marks 20)
Task 1 (Total Marks 10)
Criteria Marks HD DI   CR PS     Program                     a. Execution: Program   executes Provided java     Provided java   perfectly   Provided java launches, executes and   program executes   program may be   without   program executes terminates without 1.0 without crashing   incomplete and/or crashing   without crashing crashing; program executes   with minimal   executes with   towards   with some errors as specified.   errors   some errors   intended                     output                      
  Implement Implement Implement Implement and integrate ProcessScores ProcessScores class ProcessScores classes with class with most of with majority of class with some all functions the functions and the functions and functions and
  Criteria Marks HD DI   CR PS              
  by integrate the mark integrate the mark then combine it maintaining class with it for class with it for with Marks class logical flow testing testing for testing Excellent       naming, Good naming, Most naming, Some naming, indentation, indentation, indentation, indentation, header header and header and inline and inline header and inline inline comments comments comments included comments included   included included      
        All of the Most of the   Just enough of the     required Majority of the d. Submission: the   required required   documents required documents documents with all   documents and documents and components (analysis, 1.0 and sufficient sufficient number and sufficient sufficient number testing, and output)   number of of test outputs number of test of test outputs   test outputs outputs provided     provided provided     provided            
Task 2 (Total Marks 10)
  Criteria Marks HD DI CR PS     Program Provided java     a. Execution: Program   executes   Provided java   program Provided java launches, executes and   perfectly program may be   executes program executes terminates without crashing; 1.0 without incomplete and/or without without crashing program executes as   crashing executes with   crashing with with some errors specified.   towards some errors   minimal errors       intended output    
    Implement and Implement and Implement Light Implement Light   integrate all of integrate most and TestLight and TestLight   of the Light and classes with classes with some 6.0 the Light and TestLight majority functions functions and   TestLight   classes and combine them combine them for   classes   functionaliies for testing testing       UML with all UML with most UML with UML with   components components and majority incomplete 1.0 and their their parameter, components and components and   parameter, and and return their parameter, their parameter,   return and return and return       All of the Most of the Majority of the Just enough of the   required required   required required   documents and documents and   documents and documents and 1.0 sufficient sufficient sufficient number sufficient number   number of test number of test   of test outputs of test outputs   outputs outputs   provided provided   provided provided         All of the Most of the Majority of the Just enough of the   required required   required required   documents and documents and   documents and documents and 1.0 sufficient sufficient sufficient number sufficient number   number of test number of test   of test outputs of test outputs   outputs outputs   provided provided   provided provided      
Punjab Assignment Help
Buy Online Assignment Help services for JAVA ASSIGNMENT with Punjab Assignment Help at [email protected]
0 notes
gurnam36-blog · 7 years ago
Photo
Tumblr media
New Post has been published on https://punjabassignmenthelp.com/itc538-designing-object-oriented-program/
ITC538 | DESIGNING OBJECT ORIENTED PROGRAM
ITC538 | DESIGNING OBJECT ORIENTED PROGRAM | JAVA
JAVA ASSIGNMENT HELP
Task
Assessment 2 has 20 marks in total. Marks will be scaled according to the value of the assessment.
There are two tasks in assessment 2, Task 1 and Task 2 as below:
Task 1: Value 10 marks
Suppose you are commissioned by the Australian Football Association (AFL) to write a program designed to produce statistics based on complete scores recorded in a season. These scores are kept in a file called afl.txt (available on interact resources). You are also given the following information about a football season:
League consists of 18 football teams
There are 22 rounds in each season
In each round teams play against each other and the score of each team is recorded as an integer and kept in the text file referred to above (aft.txt)
Your task is to write a complete java program (a java class with the main method) called ProcessScores, which will read the scores from the text file provided, store the scores in an array of integers and then using a number of independent staticmethods, calculate and display the required statistics relating the afl scores.
The java class you are required to author will contain the following static methods:
lowest will take the array of scores as an argument and return the lowest score in the season highest will take the array of scores as an argument and return the highest score in the season
range will take the array of scores as an argument and return the difference between the highest score and the lowest score in the season
average will take the array of scores as an argument and return the average of all scores in the season
median will take the array of scores as an argument and return the median score in the season
mode will take the array of scores as an argument and return the mode of the scores in the season
Note that all of the methods described above, should be static methods; user defined methods (you have the write the definition of each yourself); and completely independent of each other (you should not invoke anyone of them within the other method definition). Also, the original array of scores should not be modified by any of the methods.
Ensure that the program is appropriately documented throughout and thoroughly tested to demonstrate its correct operation.
You need to submit java and class files, a short discussion to explain the logic on how the problem has been solved, and sample output (for detail please see marking guide and presentation below).
Task 2: Value 10 marks
Design a class named Light to represent a conference hall light. The class contains:
Three constants named LOW, MEDIUM, and HIGH with the values 1, 2, and 3 to denote Charles Sturt University Subject Outline the light brightness.
A private int data field named brightness that specifies the brightness of the light having a default value of LOW.
A private boolean data field named on that specifies whether the light is on or off having a default value of false.
A string data field named color that specifies the color of the light having a default value of red.
The accessor and mutator methods for all three data fields.
A no-arg/default constructor that creates a default light.
A method named toString() that returns a string description for the light. If the light is on, the method returns the fan brightness and color in one combined string. If the light is not on, the method returns the fan color along with the string “light is off” in one combined string. Draw the UML diagram for the class and then implement the class.
Write a test program TestLight that creates two Light objects. Assign high brightness, color yellow, and turn it on to the first object. Assign medium brightness, color blue, and turn it off to the second object. Display the objects by invoking their respective toString methods.
Ensure that the program is appropriately documented throughout and thoroughly tested to demonstrate its correct operation.
You need to submit java and class files, a short discussion to explain the logic on how the problem has been solved, UML diagram, and sample output (for detail please see marking guide and presentation below).
  Rationale
This assignment has been designed to allow students to test and demonstrate their ability to:
design and implement algorithms in Java (learning outcome 1);
interpret and evaluate design requirements expressed in Unified Modelling Language (UML) (learning outcome 2);
use object-oriented techniques and Java resources to develop small applications consisting of a number of classes (learning outcome 4);
apply testing and debugging techniques in program development (learning outcome 5);
Marking criteria
Assessment 2 (Total Marks 20)
Task 1 (Total Marks 10)
Criteria Marks HD DI   CR PS     Program                     a. Execution: Program   executes Provided java     Provided java   perfectly   Provided java launches, executes and   program executes   program may be   without   program executes terminates without 1.0 without crashing   incomplete and/or crashing   without crashing crashing; program executes   with minimal   executes with   towards   with some errors as specified.   errors   some errors   intended                     output                      
  Implement Implement Implement Implement and integrate ProcessScores ProcessScores class ProcessScores classes with class with most of with majority of class with some all functions the functions and the functions and functions and
  Criteria Marks HD DI   CR PS              
  by integrate the mark integrate the mark then combine it maintaining class with it for class with it for with Marks class logical flow testing testing for testing Excellent       naming, Good naming, Most naming, Some naming, indentation, indentation, indentation, indentation, header header and header and inline and inline header and inline inline comments comments comments included comments included   included included      
        All of the Most of the   Just enough of the     required Majority of the d. Submission: the   required required   documents required documents documents with all   documents and documents and components (analysis, 1.0 and sufficient sufficient number and sufficient sufficient number testing, and output)   number of of test outputs number of test of test outputs   test outputs outputs provided     provided provided     provided            
Task 2 (Total Marks 10)
  Criteria Marks HD DI CR PS     Program Provided java     a. Execution: Program   executes   Provided java   program Provided java launches, executes and   perfectly program may be   executes program executes terminates without crashing; 1.0 without incomplete and/or without without crashing program executes as   crashing executes with   crashing with with some errors specified.   towards some errors   minimal errors       intended output    
    Implement and Implement and Implement Light Implement Light   integrate all of integrate most and TestLight and TestLight   of the Light and classes with classes with some 6.0 the Light and TestLight majority functions functions and   TestLight   classes and combine them combine them for   classes   functionaliies for testing testing       UML with all UML with most UML with UML with   components components and majority incomplete 1.0 and their their parameter, components and components and   parameter, and and return their parameter, their parameter,   return and return and return       All of the Most of the Majority of the Just enough of the   required required   required required   documents and documents and   documents and documents and 1.0 sufficient sufficient sufficient number sufficient number   number of test number of test   of test outputs of test outputs   outputs outputs   provided provided   provided provided         All of the Most of the Majority of the Just enough of the   required required   required required   documents and documents and   documents and documents and 1.0 sufficient sufficient sufficient number sufficient number   number of test number of test   of test outputs of test outputs   outputs outputs   provided provided   provided provided      
Punjab Assignment Help
Buy Online Assignment Help services for JAVA ASSIGNMENT with Punjab Assignment Help at [email protected]
0 notes
sandeep94674-blog · 7 years ago
Text
ITC538 | DESIGNING OBJECT ORIENTED PROGRAM
New Post has been published on https://punjabassignmenthelp.com/itc538-designing-object-oriented-program/
ITC538 | DESIGNING OBJECT ORIENTED PROGRAM
ITC538 | DESIGNING OBJECT ORIENTED PROGRAM | JAVA
JAVA ASSIGNMENT HELP
Task
Assessment 2 has 20 marks in total. Marks will be scaled according to the value of the assessment.
There are two tasks in assessment 2, Task 1 and Task 2 as below:
Task 1: Value 10 marks
Suppose you are commissioned by the Australian Football Association (AFL) to write a program designed to produce statistics based on complete scores recorded in a season. These scores are kept in a file called afl.txt (available on interact resources). You are also given the following information about a football season:
League consists of 18 football teams
There are 22 rounds in each season
In each round teams play against each other and the score of each team is recorded as an integer and kept in the text file referred to above (aft.txt)
Your task is to write a complete java program (a java class with the main method) called ProcessScores, which will read the scores from the text file provided, store the scores in an array of integers and then using a number of independent staticmethods, calculate and display the required statistics relating the afl scores.
The java class you are required to author will contain the following static methods:
lowest will take the array of scores as an argument and return the lowest score in the season highest will take the array of scores as an argument and return the highest score in the season
range will take the array of scores as an argument and return the difference between the highest score and the lowest score in the season
average will take the array of scores as an argument and return the average of all scores in the season
median will take the array of scores as an argument and return the median score in the season
mode will take the array of scores as an argument and return the mode of the scores in the season
Note that all of the methods described above, should be static methods; user defined methods (you have the write the definition of each yourself); and completely independent of each other (you should not invoke anyone of them within the other method definition). Also, the original array of scores should not be modified by any of the methods.
Ensure that the program is appropriately documented throughout and thoroughly tested to demonstrate its correct operation.
You need to submit java and class files, a short discussion to explain the logic on how the problem has been solved, and sample output (for detail please see marking guide and presentation below).
Task 2: Value 10 marks
Design a class named Light to represent a conference hall light. The class contains:
Three constants named LOW, MEDIUM, and HIGH with the values 1, 2, and 3 to denote Charles Sturt University Subject Outline the light brightness.
A private int data field named brightness that specifies the brightness of the light having a default value of LOW.
A private boolean data field named on that specifies whether the light is on or off having a default value of false.
A string data field named color that specifies the color of the light having a default value of red.
The accessor and mutator methods for all three data fields.
A no-arg/default constructor that creates a default light.
A method named toString() that returns a string description for the light. If the light is on, the method returns the fan brightness and color in one combined string. If the light is not on, the method returns the fan color along with the string “light is off” in one combined string. Draw the UML diagram for the class and then implement the class.
Write a test program TestLight that creates two Light objects. Assign high brightness, color yellow, and turn it on to the first object. Assign medium brightness, color blue, and turn it off to the second object. Display the objects by invoking their respective toString methods.
Ensure that the program is appropriately documented throughout and thoroughly tested to demonstrate its correct operation.
You need to submit java and class files, a short discussion to explain the logic on how the problem has been solved, UML diagram, and sample output (for detail please see marking guide and presentation below).
  Rationale
This assignment has been designed to allow students to test and demonstrate their ability to:
design and implement algorithms in Java (learning outcome 1);
interpret and evaluate design requirements expressed in Unified Modelling Language (UML) (learning outcome 2);
use object-oriented techniques and Java resources to develop small applications consisting of a number of classes (learning outcome 4);
apply testing and debugging techniques in program development (learning outcome 5);
Marking criteria
Assessment 2 (Total Marks 20)
Task 1 (Total Marks 10)
Criteria Marks HD DI   CR PS     Program                     a. Execution: Program   executes Provided java     Provided java   perfectly   Provided java launches, executes and   program executes   program may be   without   program executes terminates without 1.0 without crashing   incomplete and/or crashing   without crashing crashing; program executes   with minimal   executes with   towards   with some errors as specified.   errors   some errors   intended                     output                      
  Implement Implement Implement Implement and integrate ProcessScores ProcessScores class ProcessScores classes with class with most of with majority of class with some all functions the functions and the functions and functions and
  Criteria Marks HD DI   CR PS              
  by integrate the mark integrate the mark then combine it maintaining class with it for class with it for with Marks class logical flow testing testing for testing Excellent       naming, Good naming, Most naming, Some naming, indentation, indentation, indentation, indentation, header header and header and inline and inline header and inline inline comments comments comments included comments included   included included      
        All of the Most of the   Just enough of the     required Majority of the d. Submission: the   required required   documents required documents documents with all   documents and documents and components (analysis, 1.0 and sufficient sufficient number and sufficient sufficient number testing, and output)   number of of test outputs number of test of test outputs   test outputs outputs provided     provided provided     provided            
Task 2 (Total Marks 10)
  Criteria Marks HD DI CR PS     Program Provided java     a. Execution: Program   executes   Provided java   program Provided java launches, executes and   perfectly program may be   executes program executes terminates without crashing; 1.0 without incomplete and/or without without crashing program executes as   crashing executes with   crashing with with some errors specified.   towards some errors   minimal errors       intended output    
    Implement and Implement and Implement Light Implement Light   integrate all of integrate most and TestLight and TestLight   of the Light and classes with classes with some 6.0 the Light and TestLight majority functions functions and   TestLight   classes and combine them combine them for   classes   functionaliies for testing testing       UML with all UML with most UML with UML with   components components and majority incomplete 1.0 and their their parameter, components and components and   parameter, and and return their parameter, their parameter,   return and return and return       All of the Most of the Majority of the Just enough of the   required required   required required   documents and documents and   documents and documents and 1.0 sufficient sufficient sufficient number sufficient number   number of test number of test   of test outputs of test outputs   outputs outputs   provided provided   provided provided         All of the Most of the Majority of the Just enough of the   required required   required required   documents and documents and   documents and documents and 1.0 sufficient sufficient sufficient number sufficient number   number of test number of test   of test outputs of test outputs   outputs outputs   provided provided   provided provided      
Punjab Assignment Help
Buy Online Assignment Help services for JAVA ASSIGNMENT with Punjab Assignment Help at [email protected]
0 notes
mirceacazacu94-blog · 7 years ago
Photo
Tumblr media
New Post has been published on https://punjabassignmenthelp.com/itc538-designing-object-oriented-program/
ITC538 | DESIGNING OBJECT ORIENTED PROGRAM
ITC538 | DESIGNING OBJECT ORIENTED PROGRAM | JAVA
JAVA ASSIGNMENT HELP
Task
Assessment 2 has 20 marks in total. Marks will be scaled according to the value of the assessment.
There are two tasks in assessment 2, Task 1 and Task 2 as below:
Task 1: Value 10 marks
Suppose you are commissioned by the Australian Football Association (AFL) to write a program designed to produce statistics based on complete scores recorded in a season. These scores are kept in a file called afl.txt (available on interact resources). You are also given the following information about a football season:
League consists of 18 football teams
There are 22 rounds in each season
In each round teams play against each other and the score of each team is recorded as an integer and kept in the text file referred to above (aft.txt)
Your task is to write a complete java program (a java class with the main method) called ProcessScores, which will read the scores from the text file provided, store the scores in an array of integers and then using a number of independent staticmethods, calculate and display the required statistics relating the afl scores.
The java class you are required to author will contain the following static methods:
lowest will take the array of scores as an argument and return the lowest score in the season highest will take the array of scores as an argument and return the highest score in the season
range will take the array of scores as an argument and return the difference between the highest score and the lowest score in the season
average will take the array of scores as an argument and return the average of all scores in the season
median will take the array of scores as an argument and return the median score in the season
mode will take the array of scores as an argument and return the mode of the scores in the season
Note that all of the methods described above, should be static methods; user defined methods (you have the write the definition of each yourself); and completely independent of each other (you should not invoke anyone of them within the other method definition). Also, the original array of scores should not be modified by any of the methods.
Ensure that the program is appropriately documented throughout and thoroughly tested to demonstrate its correct operation.
You need to submit java and class files, a short discussion to explain the logic on how the problem has been solved, and sample output (for detail please see marking guide and presentation below).
Task 2: Value 10 marks
Design a class named Light to represent a conference hall light. The class contains:
Three constants named LOW, MEDIUM, and HIGH with the values 1, 2, and 3 to denote Charles Sturt University Subject Outline the light brightness.
A private int data field named brightness that specifies the brightness of the light having a default value of LOW.
A private boolean data field named on that specifies whether the light is on or off having a default value of false.
A string data field named color that specifies the color of the light having a default value of red.
The accessor and mutator methods for all three data fields.
A no-arg/default constructor that creates a default light.
A method named toString() that returns a string description for the light. If the light is on, the method returns the fan brightness and color in one combined string. If the light is not on, the method returns the fan color along with the string “light is off” in one combined string. Draw the UML diagram for the class and then implement the class.
Write a test program TestLight that creates two Light objects. Assign high brightness, color yellow, and turn it on to the first object. Assign medium brightness, color blue, and turn it off to the second object. Display the objects by invoking their respective toString methods.
Ensure that the program is appropriately documented throughout and thoroughly tested to demonstrate its correct operation.
You need to submit java and class files, a short discussion to explain the logic on how the problem has been solved, UML diagram, and sample output (for detail please see marking guide and presentation below).
  Rationale
This assignment has been designed to allow students to test and demonstrate their ability to:
design and implement algorithms in Java (learning outcome 1);
interpret and evaluate design requirements expressed in Unified Modelling Language (UML) (learning outcome 2);
use object-oriented techniques and Java resources to develop small applications consisting of a number of classes (learning outcome 4);
apply testing and debugging techniques in program development (learning outcome 5);
Marking criteria
Assessment 2 (Total Marks 20)
Task 1 (Total Marks 10)
Criteria Marks HD DI   CR PS     Program                     a. Execution: Program   executes Provided java     Provided java   perfectly   Provided java launches, executes and   program executes   program may be   without   program executes terminates without 1.0 without crashing   incomplete and/or crashing   without crashing crashing; program executes   with minimal   executes with   towards   with some errors as specified.   errors   some errors   intended                     output                      
  Implement Implement Implement Implement and integrate ProcessScores ProcessScores class ProcessScores classes with class with most of with majority of class with some all functions the functions and the functions and functions and
  Criteria Marks HD DI   CR PS              
  by integrate the mark integrate the mark then combine it maintaining class with it for class with it for with Marks class logical flow testing testing for testing Excellent       naming, Good naming, Most naming, Some naming, indentation, indentation, indentation, indentation, header header and header and inline and inline header and inline inline comments comments comments included comments included   included included      
        All of the Most of the   Just enough of the     required Majority of the d. Submission: the   required required   documents required documents documents with all   documents and documents and components (analysis, 1.0 and sufficient sufficient number and sufficient sufficient number testing, and output)   number of of test outputs number of test of test outputs   test outputs outputs provided     provided provided     provided            
Task 2 (Total Marks 10)
  Criteria Marks HD DI CR PS     Program Provided java     a. Execution: Program   executes   Provided java   program Provided java launches, executes and   perfectly program may be   executes program executes terminates without crashing; 1.0 without incomplete and/or without without crashing program executes as   crashing executes with   crashing with with some errors specified.   towards some errors   minimal errors       intended output    
    Implement and Implement and Implement Light Implement Light   integrate all of integrate most and TestLight and TestLight   of the Light and classes with classes with some 6.0 the Light and TestLight majority functions functions and   TestLight   classes and combine them combine them for   classes   functionaliies for testing testing       UML with all UML with most UML with UML with   components components and majority incomplete 1.0 and their their parameter, components and components and   parameter, and and return their parameter, their parameter,   return and return and return       All of the Most of the Majority of the Just enough of the   required required   required required   documents and documents and   documents and documents and 1.0 sufficient sufficient sufficient number sufficient number   number of test number of test   of test outputs of test outputs   outputs outputs   provided provided   provided provided         All of the Most of the Majority of the Just enough of the   required required   required required   documents and documents and   documents and documents and 1.0 sufficient sufficient sufficient number sufficient number   number of test number of test   of test outputs of test outputs   outputs outputs   provided provided   provided provided      
Punjab Assignment Help
Buy Online Assignment Help services for JAVA ASSIGNMENT with Punjab Assignment Help at [email protected]
0 notes
alicebrown52-blog · 7 years ago
Photo
Tumblr media
New Post has been published on https://punjabassignmenthelp.com/itc538-designing-object-oriented-program/
ITC538 | DESIGNING OBJECT ORIENTED PROGRAM
ITC538 | DESIGNING OBJECT ORIENTED PROGRAM | JAVA
JAVA ASSIGNMENT HELP
Task
Assessment 2 has 20 marks in total. Marks will be scaled according to the value of the assessment.
There are two tasks in assessment 2, Task 1 and Task 2 as below:
Task 1: Value 10 marks
Suppose you are commissioned by the Australian Football Association (AFL) to write a program designed to produce statistics based on complete scores recorded in a season. These scores are kept in a file called afl.txt (available on interact resources). You are also given the following information about a football season:
League consists of 18 football teams
There are 22 rounds in each season
In each round teams play against each other and the score of each team is recorded as an integer and kept in the text file referred to above (aft.txt)
Your task is to write a complete java program (a java class with the main method) called ProcessScores, which will read the scores from the text file provided, store the scores in an array of integers and then using a number of independent staticmethods, calculate and display the required statistics relating the afl scores.
The java class you are required to author will contain the following static methods:
lowest will take the array of scores as an argument and return the lowest score in the season highest will take the array of scores as an argument and return the highest score in the season
range will take the array of scores as an argument and return the difference between the highest score and the lowest score in the season
average will take the array of scores as an argument and return the average of all scores in the season
median will take the array of scores as an argument and return the median score in the season
mode will take the array of scores as an argument and return the mode of the scores in the season
Note that all of the methods described above, should be static methods; user defined methods (you have the write the definition of each yourself); and completely independent of each other (you should not invoke anyone of them within the other method definition). Also, the original array of scores should not be modified by any of the methods.
Ensure that the program is appropriately documented throughout and thoroughly tested to demonstrate its correct operation.
You need to submit java and class files, a short discussion to explain the logic on how the problem has been solved, and sample output (for detail please see marking guide and presentation below).
Task 2: Value 10 marks
Design a class named Light to represent a conference hall light. The class contains:
Three constants named LOW, MEDIUM, and HIGH with the values 1, 2, and 3 to denote Charles Sturt University Subject Outline the light brightness.
A private int data field named brightness that specifies the brightness of the light having a default value of LOW.
A private boolean data field named on that specifies whether the light is on or off having a default value of false.
A string data field named color that specifies the color of the light having a default value of red.
The accessor and mutator methods for all three data fields.
A no-arg/default constructor that creates a default light.
A method named toString() that returns a string description for the light. If the light is on, the method returns the fan brightness and color in one combined string. If the light is not on, the method returns the fan color along with the string “light is off” in one combined string. Draw the UML diagram for the class and then implement the class.
Write a test program TestLight that creates two Light objects. Assign high brightness, color yellow, and turn it on to the first object. Assign medium brightness, color blue, and turn it off to the second object. Display the objects by invoking their respective toString methods.
Ensure that the program is appropriately documented throughout and thoroughly tested to demonstrate its correct operation.
You need to submit java and class files, a short discussion to explain the logic on how the problem has been solved, UML diagram, and sample output (for detail please see marking guide and presentation below).
  Rationale
This assignment has been designed to allow students to test and demonstrate their ability to:
design and implement algorithms in Java (learning outcome 1);
interpret and evaluate design requirements expressed in Unified Modelling Language (UML) (learning outcome 2);
use object-oriented techniques and Java resources to develop small applications consisting of a number of classes (learning outcome 4);
apply testing and debugging techniques in program development (learning outcome 5);
Marking criteria
Assessment 2 (Total Marks 20)
Task 1 (Total Marks 10)
Criteria Marks HD DI   CR PS     Program                     a. Execution: Program   executes Provided java     Provided java   perfectly   Provided java launches, executes and   program executes   program may be   without   program executes terminates without 1.0 without crashing   incomplete and/or crashing   without crashing crashing; program executes   with minimal   executes with   towards   with some errors as specified.   errors   some errors   intended                     output                      
  Implement Implement Implement Implement and integrate ProcessScores ProcessScores class ProcessScores classes with class with most of with majority of class with some all functions the functions and the functions and functions and
  Criteria Marks HD DI   CR PS              
  by integrate the mark integrate the mark then combine it maintaining class with it for class with it for with Marks class logical flow testing testing for testing Excellent       naming, Good naming, Most naming, Some naming, indentation, indentation, indentation, indentation, header header and header and inline and inline header and inline inline comments comments comments included comments included   included included      
        All of the Most of the   Just enough of the     required Majority of the d. Submission: the   required required   documents required documents documents with all   documents and documents and components (analysis, 1.0 and sufficient sufficient number and sufficient sufficient number testing, and output)   number of of test outputs number of test of test outputs   test outputs outputs provided     provided provided     provided            
Task 2 (Total Marks 10)
  Criteria Marks HD DI CR PS     Program Provided java     a. Execution: Program   executes   Provided java   program Provided java launches, executes and   perfectly program may be   executes program executes terminates without crashing; 1.0 without incomplete and/or without without crashing program executes as   crashing executes with   crashing with with some errors specified.   towards some errors   minimal errors       intended output    
    Implement and Implement and Implement Light Implement Light   integrate all of integrate most and TestLight and TestLight   of the Light and classes with classes with some 6.0 the Light and TestLight majority functions functions and   TestLight   classes and combine them combine them for   classes   functionaliies for testing testing       UML with all UML with most UML with UML with   components components and majority incomplete 1.0 and their their parameter, components and components and   parameter, and and return their parameter, their parameter,   return and return and return       All of the Most of the Majority of the Just enough of the   required required   required required   documents and documents and   documents and documents and 1.0 sufficient sufficient sufficient number sufficient number   number of test number of test   of test outputs of test outputs   outputs outputs   provided provided   provided provided         All of the Most of the Majority of the Just enough of the   required required   required required   documents and documents and   documents and documents and 1.0 sufficient sufficient sufficient number sufficient number   number of test number of test   of test outputs of test outputs   outputs outputs   provided provided   provided provided      
Punjab Assignment Help
Buy Online Assignment Help services for JAVA ASSIGNMENT with Punjab Assignment Help at [email protected]
0 notes
achalpatel5-blog · 7 years ago
Photo
Tumblr media
New Post has been published on https://punjabassignmenthelp.com/itc538-designing-object-oriented-program/
ITC538 | DESIGNING OBJECT ORIENTED PROGRAM
ITC538 | DESIGNING OBJECT ORIENTED PROGRAM | JAVA
JAVA ASSIGNMENT HELP
Task
Assessment 2 has 20 marks in total. Marks will be scaled according to the value of the assessment.
There are two tasks in assessment 2, Task 1 and Task 2 as below:
Task 1: Value 10 marks
Suppose you are commissioned by the Australian Football Association (AFL) to write a program designed to produce statistics based on complete scores recorded in a season. These scores are kept in a file called afl.txt (available on interact resources). You are also given the following information about a football season:
League consists of 18 football teams
There are 22 rounds in each season
In each round teams play against each other and the score of each team is recorded as an integer and kept in the text file referred to above (aft.txt)
Your task is to write a complete java program (a java class with the main method) called ProcessScores, which will read the scores from the text file provided, store the scores in an array of integers and then using a number of independent staticmethods, calculate and display the required statistics relating the afl scores.
The java class you are required to author will contain the following static methods:
lowest will take the array of scores as an argument and return the lowest score in the season highest will take the array of scores as an argument and return the highest score in the season
range will take the array of scores as an argument and return the difference between the highest score and the lowest score in the season
average will take the array of scores as an argument and return the average of all scores in the season
median will take the array of scores as an argument and return the median score in the season
mode will take the array of scores as an argument and return the mode of the scores in the season
Note that all of the methods described above, should be static methods; user defined methods (you have the write the definition of each yourself); and completely independent of each other (you should not invoke anyone of them within the other method definition). Also, the original array of scores should not be modified by any of the methods.
Ensure that the program is appropriately documented throughout and thoroughly tested to demonstrate its correct operation.
You need to submit java and class files, a short discussion to explain the logic on how the problem has been solved, and sample output (for detail please see marking guide and presentation below).
Task 2: Value 10 marks
Design a class named Light to represent a conference hall light. The class contains:
Three constants named LOW, MEDIUM, and HIGH with the values 1, 2, and 3 to denote Charles Sturt University Subject Outline the light brightness.
A private int data field named brightness that specifies the brightness of the light having a default value of LOW.
A private boolean data field named on that specifies whether the light is on or off having a default value of false.
A string data field named color that specifies the color of the light having a default value of red.
The accessor and mutator methods for all three data fields.
A no-arg/default constructor that creates a default light.
A method named toString() that returns a string description for the light. If the light is on, the method returns the fan brightness and color in one combined string. If the light is not on, the method returns the fan color along with the string “light is off” in one combined string. Draw the UML diagram for the class and then implement the class.
Write a test program TestLight that creates two Light objects. Assign high brightness, color yellow, and turn it on to the first object. Assign medium brightness, color blue, and turn it off to the second object. Display the objects by invoking their respective toString methods.
Ensure that the program is appropriately documented throughout and thoroughly tested to demonstrate its correct operation.
You need to submit java and class files, a short discussion to explain the logic on how the problem has been solved, UML diagram, and sample output (for detail please see marking guide and presentation below).
  Rationale
This assignment has been designed to allow students to test and demonstrate their ability to:
design and implement algorithms in Java (learning outcome 1);
interpret and evaluate design requirements expressed in Unified Modelling Language (UML) (learning outcome 2);
use object-oriented techniques and Java resources to develop small applications consisting of a number of classes (learning outcome 4);
apply testing and debugging techniques in program development (learning outcome 5);
Marking criteria
Assessment 2 (Total Marks 20)
Task 1 (Total Marks 10)
Criteria Marks HD DI   CR PS     Program                     a. Execution: Program   executes Provided java     Provided java   perfectly   Provided java launches, executes and   program executes   program may be   without   program executes terminates without 1.0 without crashing   incomplete and/or crashing   without crashing crashing; program executes   with minimal   executes with   towards   with some errors as specified.   errors   some errors   intended                     output                      
  Implement Implement Implement Implement and integrate ProcessScores ProcessScores class ProcessScores classes with class with most of with majority of class with some all functions the functions and the functions and functions and
  Criteria Marks HD DI   CR PS              
  by integrate the mark integrate the mark then combine it maintaining class with it for class with it for with Marks class logical flow testing testing for testing Excellent       naming, Good naming, Most naming, Some naming, indentation, indentation, indentation, indentation, header header and header and inline and inline header and inline inline comments comments comments included comments included   included included      
        All of the Most of the   Just enough of the     required Majority of the d. Submission: the   required required   documents required documents documents with all   documents and documents and components (analysis, 1.0 and sufficient sufficient number and sufficient sufficient number testing, and output)   number of of test outputs number of test of test outputs   test outputs outputs provided     provided provided     provided            
Task 2 (Total Marks 10)
  Criteria Marks HD DI CR PS     Program Provided java     a. Execution: Program   executes   Provided java   program Provided java launches, executes and   perfectly program may be   executes program executes terminates without crashing; 1.0 without incomplete and/or without without crashing program executes as   crashing executes with   crashing with with some errors specified.   towards some errors   minimal errors       intended output    
    Implement and Implement and Implement Light Implement Light   integrate all of integrate most and TestLight and TestLight   of the Light and classes with classes with some 6.0 the Light and TestLight majority functions functions and   TestLight   classes and combine them combine them for   classes   functionaliies for testing testing       UML with all UML with most UML with UML with   components components and majority incomplete 1.0 and their their parameter, components and components and   parameter, and and return their parameter, their parameter,   return and return and return       All of the Most of the Majority of the Just enough of the   required required   required required   documents and documents and   documents and documents and 1.0 sufficient sufficient sufficient number sufficient number   number of test number of test   of test outputs of test outputs   outputs outputs   provided provided   provided provided         All of the Most of the Majority of the Just enough of the   required required   required required   documents and documents and   documents and documents and 1.0 sufficient sufficient sufficient number sufficient number   number of test number of test   of test outputs of test outputs   outputs outputs   provided provided   provided provided      
Punjab Assignment Help
Buy Online Assignment Help services for JAVA ASSIGNMENT with Punjab Assignment Help at [email protected]
0 notes
deep94161-blog · 7 years ago
Text
ITC538 | DESIGNING OBJECT ORIENTED PROGRAM
New Post has been published on https://punjabassignmenthelp.com/itc538-designing-object-oriented-program/
ITC538 | DESIGNING OBJECT ORIENTED PROGRAM
ITC538 | DESIGNING OBJECT ORIENTED PROGRAM | JAVA
JAVA ASSIGNMENT HELP
Task
Assessment 2 has 20 marks in total. Marks will be scaled according to the value of the assessment.
There are two tasks in assessment 2, Task 1 and Task 2 as below:
Task 1: Value 10 marks
Suppose you are commissioned by the Australian Football Association (AFL) to write a program designed to produce statistics based on complete scores recorded in a season. These scores are kept in a file called afl.txt (available on interact resources). You are also given the following information about a football season:
League consists of 18 football teams
There are 22 rounds in each season
In each round teams play against each other and the score of each team is recorded as an integer and kept in the text file referred to above (aft.txt)
Your task is to write a complete java program (a java class with the main method) called ProcessScores, which will read the scores from the text file provided, store the scores in an array of integers and then using a number of independent staticmethods, calculate and display the required statistics relating the afl scores.
The java class you are required to author will contain the following static methods:
lowest will take the array of scores as an argument and return the lowest score in the season highest will take the array of scores as an argument and return the highest score in the season
range will take the array of scores as an argument and return the difference between the highest score and the lowest score in the season
average will take the array of scores as an argument and return the average of all scores in the season
median will take the array of scores as an argument and return the median score in the season
mode will take the array of scores as an argument and return the mode of the scores in the season
Note that all of the methods described above, should be static methods; user defined methods (you have the write the definition of each yourself); and completely independent of each other (you should not invoke anyone of them within the other method definition). Also, the original array of scores should not be modified by any of the methods.
Ensure that the program is appropriately documented throughout and thoroughly tested to demonstrate its correct operation.
You need to submit java and class files, a short discussion to explain the logic on how the problem has been solved, and sample output (for detail please see marking guide and presentation below).
Task 2: Value 10 marks
Design a class named Light to represent a conference hall light. The class contains:
Three constants named LOW, MEDIUM, and HIGH with the values 1, 2, and 3 to denote Charles Sturt University Subject Outline the light brightness.
A private int data field named brightness that specifies the brightness of the light having a default value of LOW.
A private boolean data field named on that specifies whether the light is on or off having a default value of false.
A string data field named color that specifies the color of the light having a default value of red.
The accessor and mutator methods for all three data fields.
A no-arg/default constructor that creates a default light.
A method named toString() that returns a string description for the light. If the light is on, the method returns the fan brightness and color in one combined string. If the light is not on, the method returns the fan color along with the string “light is off” in one combined string. Draw the UML diagram for the class and then implement the class.
Write a test program TestLight that creates two Light objects. Assign high brightness, color yellow, and turn it on to the first object. Assign medium brightness, color blue, and turn it off to the second object. Display the objects by invoking their respective toString methods.
Ensure that the program is appropriately documented throughout and thoroughly tested to demonstrate its correct operation.
You need to submit java and class files, a short discussion to explain the logic on how the problem has been solved, UML diagram, and sample output (for detail please see marking guide and presentation below).
  Rationale
This assignment has been designed to allow students to test and demonstrate their ability to:
design and implement algorithms in Java (learning outcome 1);
interpret and evaluate design requirements expressed in Unified Modelling Language (UML) (learning outcome 2);
use object-oriented techniques and Java resources to develop small applications consisting of a number of classes (learning outcome 4);
apply testing and debugging techniques in program development (learning outcome 5);
Marking criteria
Assessment 2 (Total Marks 20)
Task 1 (Total Marks 10)
Criteria Marks HD DI   CR PS     Program                     a. Execution: Program   executes Provided java     Provided java   perfectly   Provided java launches, executes and   program executes   program may be   without   program executes terminates without 1.0 without crashing   incomplete and/or crashing   without crashing crashing; program executes   with minimal   executes with   towards   with some errors as specified.   errors   some errors   intended                     output                      
  Implement Implement Implement Implement and integrate ProcessScores ProcessScores class ProcessScores classes with class with most of with majority of class with some all functions the functions and the functions and functions and
  Criteria Marks HD DI   CR PS              
  by integrate the mark integrate the mark then combine it maintaining class with it for class with it for with Marks class logical flow testing testing for testing Excellent       naming, Good naming, Most naming, Some naming, indentation, indentation, indentation, indentation, header header and header and inline and inline header and inline inline comments comments comments included comments included   included included      
        All of the Most of the   Just enough of the     required Majority of the d. Submission: the   required required   documents required documents documents with all   documents and documents and components (analysis, 1.0 and sufficient sufficient number and sufficient sufficient number testing, and output)   number of of test outputs number of test of test outputs   test outputs outputs provided     provided provided     provided            
Task 2 (Total Marks 10)
  Criteria Marks HD DI CR PS     Program Provided java     a. Execution: Program   executes   Provided java   program Provided java launches, executes and   perfectly program may be   executes program executes terminates without crashing; 1.0 without incomplete and/or without without crashing program executes as   crashing executes with   crashing with with some errors specified.   towards some errors   minimal errors       intended output    
    Implement and Implement and Implement Light Implement Light   integrate all of integrate most and TestLight and TestLight   of the Light and classes with classes with some 6.0 the Light and TestLight majority functions functions and   TestLight   classes and combine them combine them for   classes   functionaliies for testing testing       UML with all UML with most UML with UML with   components components and majority incomplete 1.0 and their their parameter, components and components and   parameter, and and return their parameter, their parameter,   return and return and return       All of the Most of the Majority of the Just enough of the   required required   required required   documents and documents and   documents and documents and 1.0 sufficient sufficient sufficient number sufficient number   number of test number of test   of test outputs of test outputs   outputs outputs   provided provided   provided provided         All of the Most of the Majority of the Just enough of the   required required   required required   documents and documents and   documents and documents and 1.0 sufficient sufficient sufficient number sufficient number   number of test number of test   of test outputs of test outputs   outputs outputs   provided provided   provided provided      
Punjab Assignment Help
Buy Online Assignment Help services for JAVA ASSIGNMENT with Punjab Assignment Help at [email protected]
0 notes
monicagill123-blog · 7 years ago
Photo
Tumblr media
New Post has been published on https://punjabassignmenthelp.com/itc538-designing-object-oriented-program/
ITC538 | DESIGNING OBJECT ORIENTED PROGRAM
ITC538 | DESIGNING OBJECT ORIENTED PROGRAM | JAVA
JAVA ASSIGNMENT HELP
Task
Assessment 2 has 20 marks in total. Marks will be scaled according to the value of the assessment.
There are two tasks in assessment 2, Task 1 and Task 2 as below:
Task 1: Value 10 marks
Suppose you are commissioned by the Australian Football Association (AFL) to write a program designed to produce statistics based on complete scores recorded in a season. These scores are kept in a file called afl.txt (available on interact resources). You are also given the following information about a football season:
League consists of 18 football teams
There are 22 rounds in each season
In each round teams play against each other and the score of each team is recorded as an integer and kept in the text file referred to above (aft.txt)
Your task is to write a complete java program (a java class with the main method) called ProcessScores, which will read the scores from the text file provided, store the scores in an array of integers and then using a number of independent staticmethods, calculate and display the required statistics relating the afl scores.
The java class you are required to author will contain the following static methods:
lowest will take the array of scores as an argument and return the lowest score in the season highest will take the array of scores as an argument and return the highest score in the season
range will take the array of scores as an argument and return the difference between the highest score and the lowest score in the season
average will take the array of scores as an argument and return the average of all scores in the season
median will take the array of scores as an argument and return the median score in the season
mode will take the array of scores as an argument and return the mode of the scores in the season
Note that all of the methods described above, should be static methods; user defined methods (you have the write the definition of each yourself); and completely independent of each other (you should not invoke anyone of them within the other method definition). Also, the original array of scores should not be modified by any of the methods.
Ensure that the program is appropriately documented throughout and thoroughly tested to demonstrate its correct operation.
You need to submit java and class files, a short discussion to explain the logic on how the problem has been solved, and sample output (for detail please see marking guide and presentation below).
Task 2: Value 10 marks
Design a class named Light to represent a conference hall light. The class contains:
Three constants named LOW, MEDIUM, and HIGH with the values 1, 2, and 3 to denote Charles Sturt University Subject Outline the light brightness.
A private int data field named brightness that specifies the brightness of the light having a default value of LOW.
A private boolean data field named on that specifies whether the light is on or off having a default value of false.
A string data field named color that specifies the color of the light having a default value of red.
The accessor and mutator methods for all three data fields.
A no-arg/default constructor that creates a default light.
A method named toString() that returns a string description for the light. If the light is on, the method returns the fan brightness and color in one combined string. If the light is not on, the method returns the fan color along with the string “light is off” in one combined string. Draw the UML diagram for the class and then implement the class.
Write a test program TestLight that creates two Light objects. Assign high brightness, color yellow, and turn it on to the first object. Assign medium brightness, color blue, and turn it off to the second object. Display the objects by invoking their respective toString methods.
Ensure that the program is appropriately documented throughout and thoroughly tested to demonstrate its correct operation.
You need to submit java and class files, a short discussion to explain the logic on how the problem has been solved, UML diagram, and sample output (for detail please see marking guide and presentation below).
  Rationale
This assignment has been designed to allow students to test and demonstrate their ability to:
design and implement algorithms in Java (learning outcome 1);
interpret and evaluate design requirements expressed in Unified Modelling Language (UML) (learning outcome 2);
use object-oriented techniques and Java resources to develop small applications consisting of a number of classes (learning outcome 4);
apply testing and debugging techniques in program development (learning outcome 5);
Marking criteria
Assessment 2 (Total Marks 20)
Task 1 (Total Marks 10)
Criteria Marks HD DI   CR PS     Program                     a. Execution: Program   executes Provided java     Provided java   perfectly   Provided java launches, executes and   program executes   program may be   without   program executes terminates without 1.0 without crashing   incomplete and/or crashing   without crashing crashing; program executes   with minimal   executes with   towards   with some errors as specified.   errors   some errors   intended                     output                      
  Implement Implement Implement Implement and integrate ProcessScores ProcessScores class ProcessScores classes with class with most of with majority of class with some all functions the functions and the functions and functions and
  Criteria Marks HD DI   CR PS              
  by integrate the mark integrate the mark then combine it maintaining class with it for class with it for with Marks class logical flow testing testing for testing Excellent       naming, Good naming, Most naming, Some naming, indentation, indentation, indentation, indentation, header header and header and inline and inline header and inline inline comments comments comments included comments included   included included      
        All of the Most of the   Just enough of the     required Majority of the d. Submission: the   required required   documents required documents documents with all   documents and documents and components (analysis, 1.0 and sufficient sufficient number and sufficient sufficient number testing, and output)   number of of test outputs number of test of test outputs   test outputs outputs provided     provided provided     provided            
Task 2 (Total Marks 10)
  Criteria Marks HD DI CR PS     Program Provided java     a. Execution: Program   executes   Provided java   program Provided java launches, executes and   perfectly program may be   executes program executes terminates without crashing; 1.0 without incomplete and/or without without crashing program executes as   crashing executes with   crashing with with some errors specified.   towards some errors   minimal errors       intended output    
    Implement and Implement and Implement Light Implement Light   integrate all of integrate most and TestLight and TestLight   of the Light and classes with classes with some 6.0 the Light and TestLight majority functions functions and   TestLight   classes and combine them combine them for   classes   functionaliies for testing testing       UML with all UML with most UML with UML with   components components and majority incomplete 1.0 and their their parameter, components and components and   parameter, and and return their parameter, their parameter,   return and return and return       All of the Most of the Majority of the Just enough of the   required required   required required   documents and documents and   documents and documents and 1.0 sufficient sufficient sufficient number sufficient number   number of test number of test   of test outputs of test outputs   outputs outputs   provided provided   provided provided         All of the Most of the Majority of the Just enough of the   required required   required required   documents and documents and   documents and documents and 1.0 sufficient sufficient sufficient number sufficient number   number of test number of test   of test outputs of test outputs   outputs outputs   provided provided   provided provided      
Punjab Assignment Help
Buy Online Assignment Help services for JAVA ASSIGNMENT with Punjab Assignment Help at [email protected]
0 notes
valeriegwavuya444-blog · 7 years ago
Photo
Tumblr media
New Post has been published on https://punjabassignmenthelp.com/itc538-designing-object-oriented-program/
ITC538 | DESIGNING OBJECT ORIENTED PROGRAM
ITC538 | DESIGNING OBJECT ORIENTED PROGRAM | JAVA
JAVA ASSIGNMENT HELP
Task
Assessment 2 has 20 marks in total. Marks will be scaled according to the value of the assessment.
There are two tasks in assessment 2, Task 1 and Task 2 as below:
Task 1: Value 10 marks
Suppose you are commissioned by the Australian Football Association (AFL) to write a program designed to produce statistics based on complete scores recorded in a season. These scores are kept in a file called afl.txt (available on interact resources). You are also given the following information about a football season:
League consists of 18 football teams
There are 22 rounds in each season
In each round teams play against each other and the score of each team is recorded as an integer and kept in the text file referred to above (aft.txt)
Your task is to write a complete java program (a java class with the main method) called ProcessScores, which will read the scores from the text file provided, store the scores in an array of integers and then using a number of independent staticmethods, calculate and display the required statistics relating the afl scores.
The java class you are required to author will contain the following static methods:
lowest will take the array of scores as an argument and return the lowest score in the season highest will take the array of scores as an argument and return the highest score in the season
range will take the array of scores as an argument and return the difference between the highest score and the lowest score in the season
average will take the array of scores as an argument and return the average of all scores in the season
median will take the array of scores as an argument and return the median score in the season
mode will take the array of scores as an argument and return the mode of the scores in the season
Note that all of the methods described above, should be static methods; user defined methods (you have the write the definition of each yourself); and completely independent of each other (you should not invoke anyone of them within the other method definition). Also, the original array of scores should not be modified by any of the methods.
Ensure that the program is appropriately documented throughout and thoroughly tested to demonstrate its correct operation.
You need to submit java and class files, a short discussion to explain the logic on how the problem has been solved, and sample output (for detail please see marking guide and presentation below).
Task 2: Value 10 marks
Design a class named Light to represent a conference hall light. The class contains:
Three constants named LOW, MEDIUM, and HIGH with the values 1, 2, and 3 to denote Charles Sturt University Subject Outline the light brightness.
A private int data field named brightness that specifies the brightness of the light having a default value of LOW.
A private boolean data field named on that specifies whether the light is on or off having a default value of false.
A string data field named color that specifies the color of the light having a default value of red.
The accessor and mutator methods for all three data fields.
A no-arg/default constructor that creates a default light.
A method named toString() that returns a string description for the light. If the light is on, the method returns the fan brightness and color in one combined string. If the light is not on, the method returns the fan color along with the string “light is off” in one combined string. Draw the UML diagram for the class and then implement the class.
Write a test program TestLight that creates two Light objects. Assign high brightness, color yellow, and turn it on to the first object. Assign medium brightness, color blue, and turn it off to the second object. Display the objects by invoking their respective toString methods.
Ensure that the program is appropriately documented throughout and thoroughly tested to demonstrate its correct operation.
You need to submit java and class files, a short discussion to explain the logic on how the problem has been solved, UML diagram, and sample output (for detail please see marking guide and presentation below).
  Rationale
This assignment has been designed to allow students to test and demonstrate their ability to:
design and implement algorithms in Java (learning outcome 1);
interpret and evaluate design requirements expressed in Unified Modelling Language (UML) (learning outcome 2);
use object-oriented techniques and Java resources to develop small applications consisting of a number of classes (learning outcome 4);
apply testing and debugging techniques in program development (learning outcome 5);
Marking criteria
Assessment 2 (Total Marks 20)
Task 1 (Total Marks 10)
Criteria Marks HD DI   CR PS     Program                     a. Execution: Program   executes Provided java     Provided java   perfectly   Provided java launches, executes and   program executes   program may be   without   program executes terminates without 1.0 without crashing   incomplete and/or crashing   without crashing crashing; program executes   with minimal   executes with   towards   with some errors as specified.   errors   some errors   intended                     output                      
  Implement Implement Implement Implement and integrate ProcessScores ProcessScores class ProcessScores classes with class with most of with majority of class with some all functions the functions and the functions and functions and
  Criteria Marks HD DI   CR PS              
  by integrate the mark integrate the mark then combine it maintaining class with it for class with it for with Marks class logical flow testing testing for testing Excellent       naming, Good naming, Most naming, Some naming, indentation, indentation, indentation, indentation, header header and header and inline and inline header and inline inline comments comments comments included comments included   included included      
        All of the Most of the   Just enough of the     required Majority of the d. Submission: the   required required   documents required documents documents with all   documents and documents and components (analysis, 1.0 and sufficient sufficient number and sufficient sufficient number testing, and output)   number of of test outputs number of test of test outputs   test outputs outputs provided     provided provided     provided            
Task 2 (Total Marks 10)
  Criteria Marks HD DI CR PS     Program Provided java     a. Execution: Program   executes   Provided java   program Provided java launches, executes and   perfectly program may be   executes program executes terminates without crashing; 1.0 without incomplete and/or without without crashing program executes as   crashing executes with   crashing with with some errors specified.   towards some errors   minimal errors       intended output    
    Implement and Implement and Implement Light Implement Light   integrate all of integrate most and TestLight and TestLight   of the Light and classes with classes with some 6.0 the Light and TestLight majority functions functions and   TestLight   classes and combine them combine them for   classes   functionaliies for testing testing       UML with all UML with most UML with UML with   components components and majority incomplete 1.0 and their their parameter, components and components and   parameter, and and return their parameter, their parameter,   return and return and return       All of the Most of the Majority of the Just enough of the   required required   required required   documents and documents and   documents and documents and 1.0 sufficient sufficient sufficient number sufficient number   number of test number of test   of test outputs of test outputs   outputs outputs   provided provided   provided provided         All of the Most of the Majority of the Just enough of the   required required   required required   documents and documents and   documents and documents and 1.0 sufficient sufficient sufficient number sufficient number   number of test number of test   of test outputs of test outputs   outputs outputs   provided provided   provided provided      
Punjab Assignment Help
Buy Online Assignment Help services for JAVA ASSIGNMENT with Punjab Assignment Help at [email protected]
0 notes
ionganuci999-blog · 7 years ago
Photo
Tumblr media
New Post has been published on https://punjabassignmenthelp.com/itc538-designing-object-oriented-program/
ITC538 | DESIGNING OBJECT ORIENTED PROGRAM
ITC538 | DESIGNING OBJECT ORIENTED PROGRAM | JAVA
JAVA ASSIGNMENT HELP
Task
Assessment 2 has 20 marks in total. Marks will be scaled according to the value of the assessment.
There are two tasks in assessment 2, Task 1 and Task 2 as below:
Task 1: Value 10 marks
Suppose you are commissioned by the Australian Football Association (AFL) to write a program designed to produce statistics based on complete scores recorded in a season. These scores are kept in a file called afl.txt (available on interact resources). You are also given the following information about a football season:
League consists of 18 football teams
There are 22 rounds in each season
In each round teams play against each other and the score of each team is recorded as an integer and kept in the text file referred to above (aft.txt)
Your task is to write a complete java program (a java class with the main method) called ProcessScores, which will read the scores from the text file provided, store the scores in an array of integers and then using a number of independent staticmethods, calculate and display the required statistics relating the afl scores.
The java class you are required to author will contain the following static methods:
lowest will take the array of scores as an argument and return the lowest score in the season highest will take the array of scores as an argument and return the highest score in the season
range will take the array of scores as an argument and return the difference between the highest score and the lowest score in the season
average will take the array of scores as an argument and return the average of all scores in the season
median will take the array of scores as an argument and return the median score in the season
mode will take the array of scores as an argument and return the mode of the scores in the season
Note that all of the methods described above, should be static methods; user defined methods (you have the write the definition of each yourself); and completely independent of each other (you should not invoke anyone of them within the other method definition). Also, the original array of scores should not be modified by any of the methods.
Ensure that the program is appropriately documented throughout and thoroughly tested to demonstrate its correct operation.
You need to submit java and class files, a short discussion to explain the logic on how the problem has been solved, and sample output (for detail please see marking guide and presentation below).
Task 2: Value 10 marks
Design a class named Light to represent a conference hall light. The class contains:
Three constants named LOW, MEDIUM, and HIGH with the values 1, 2, and 3 to denote Charles Sturt University Subject Outline the light brightness.
A private int data field named brightness that specifies the brightness of the light having a default value of LOW.
A private boolean data field named on that specifies whether the light is on or off having a default value of false.
A string data field named color that specifies the color of the light having a default value of red.
The accessor and mutator methods for all three data fields.
A no-arg/default constructor that creates a default light.
A method named toString() that returns a string description for the light. If the light is on, the method returns the fan brightness and color in one combined string. If the light is not on, the method returns the fan color along with the string “light is off” in one combined string. Draw the UML diagram for the class and then implement the class.
Write a test program TestLight that creates two Light objects. Assign high brightness, color yellow, and turn it on to the first object. Assign medium brightness, color blue, and turn it off to the second object. Display the objects by invoking their respective toString methods.
Ensure that the program is appropriately documented throughout and thoroughly tested to demonstrate its correct operation.
You need to submit java and class files, a short discussion to explain the logic on how the problem has been solved, UML diagram, and sample output (for detail please see marking guide and presentation below).
  Rationale
This assignment has been designed to allow students to test and demonstrate their ability to:
design and implement algorithms in Java (learning outcome 1);
interpret and evaluate design requirements expressed in Unified Modelling Language (UML) (learning outcome 2);
use object-oriented techniques and Java resources to develop small applications consisting of a number of classes (learning outcome 4);
apply testing and debugging techniques in program development (learning outcome 5);
Marking criteria
Assessment 2 (Total Marks 20)
Task 1 (Total Marks 10)
Criteria Marks HD DI   CR PS     Program                     a. Execution: Program   executes Provided java     Provided java   perfectly   Provided java launches, executes and   program executes   program may be   without   program executes terminates without 1.0 without crashing   incomplete and/or crashing   without crashing crashing; program executes   with minimal   executes with   towards   with some errors as specified.   errors   some errors   intended                     output                      
  Implement Implement Implement Implement and integrate ProcessScores ProcessScores class ProcessScores classes with class with most of with majority of class with some all functions the functions and the functions and functions and
  Criteria Marks HD DI   CR PS              
  by integrate the mark integrate the mark then combine it maintaining class with it for class with it for with Marks class logical flow testing testing for testing Excellent       naming, Good naming, Most naming, Some naming, indentation, indentation, indentation, indentation, header header and header and inline and inline header and inline inline comments comments comments included comments included   included included      
        All of the Most of the   Just enough of the     required Majority of the d. Submission: the   required required   documents required documents documents with all   documents and documents and components (analysis, 1.0 and sufficient sufficient number and sufficient sufficient number testing, and output)   number of of test outputs number of test of test outputs   test outputs outputs provided     provided provided     provided            
Task 2 (Total Marks 10)
  Criteria Marks HD DI CR PS     Program Provided java     a. Execution: Program   executes   Provided java   program Provided java launches, executes and   perfectly program may be   executes program executes terminates without crashing; 1.0 without incomplete and/or without without crashing program executes as   crashing executes with   crashing with with some errors specified.   towards some errors   minimal errors       intended output    
    Implement and Implement and Implement Light Implement Light   integrate all of integrate most and TestLight and TestLight   of the Light and classes with classes with some 6.0 the Light and TestLight majority functions functions and   TestLight   classes and combine them combine them for   classes   functionaliies for testing testing       UML with all UML with most UML with UML with   components components and majority incomplete 1.0 and their their parameter, components and components and   parameter, and and return their parameter, their parameter,   return and return and return       All of the Most of the Majority of the Just enough of the   required required   required required   documents and documents and   documents and documents and 1.0 sufficient sufficient sufficient number sufficient number   number of test number of test   of test outputs of test outputs   outputs outputs   provided provided   provided provided         All of the Most of the Majority of the Just enough of the   required required   required required   documents and documents and   documents and documents and 1.0 sufficient sufficient sufficient number sufficient number   number of test number of test   of test outputs of test outputs   outputs outputs   provided provided   provided provided      
Punjab Assignment Help
Buy Online Assignment Help services for JAVA ASSIGNMENT with Punjab Assignment Help at [email protected]
0 notes