ICT106–Object OrientedProgramming Assignment Total Marks:35 Assessment Weighting:25% Due Date:SundayofWeek11 Objectives This assessment task focuses on the following Learning Outcomes: •Effectively...


ICT106–Object OrientedProgramming


Assignment


Total Marks:35


Assessment Weighting:25%


Due Date:SundayofWeek11




Objectives



This assessment task focuses on the following Learning Outcomes:

•Effectively use object-oriented design and understand appropriate methodology. •Comprehend the fundamental data structures and their computational process•Create Graphic User Interfaces (GUI) by employing appropriate libraries and interfaces•Design, develop and test object-oriented programmes according to language principles

Write Java codeto develop an App.



The context for this assignment (Part 1 and Part 2) is a’Beer Bottles GameDevelopment’ for calculating and displayinga LOSER. This assignment will test a student’s knowledge of and skills in writing application software for a task, understanding the business rules of a particular problem, coding these in a computer program, developing a graphical user interface.



For this assignment, students will use the Java programming language and development will be on the NetBeans IDE platform.



This assignment consists of 2 stages,

•Part 1: A simple console program (no GUI)•Part 2: The same but wrapped in a GUI


Beer Bottles Game Development



Preamble:

1.In this game, there are 21 Beer bottles and 2 players – You and Computer.2.You and Computer would pick up the Beer bottles one by one.3.At a time, anynumberof beer bottles can be picked up between 1 and 4 (inclusive)4.The one, who will have to pick up the last bottle, is the loser and will have to pay the bill.


Design and implement a game, making use of Artificially Intelligent algorithm, so that if user is playing first, then the Computer would pick up the bottles intelligently each time, and the Computer would always Win. The Computer would never Lose.


Part 1:Design a Java application, which would display below message at the start of the game.


There are 21 beer bottles...


Computer and yourself, there are 2 players


At a time, each one can pick up anynumberof bottles between 1 and 4 (inclusive)


Will you like to play first?


If the User types ‘Yes’ and presses ‘Enter’ key, the next lines of output would be


Will you like to play first?


Yes


How many you would like to pick up?


If you pick up 3 bottles initially and press ‘Enter’ to observe how many the Computer picks now, then as per your intelligent algorithm, the Computer needs to pick up anynumberof bottles between 1 and 4 (inclusive), so that at the end, the Computer would WIN. The next set of output would be.


How many you would like to pick up?


3


Computer has picked 2


The bottles remaining are: 16


How many you would like to pick up?



The User must be able to continue the game with Computer, and at every step the remaining bottles need to be displayed appropriately. Thenumberof remaining bottles would get decreased at each step.


How many you would like to pick up?


2


Computer has picked 3


The bottles remaining are: 11


How many you would like to pick up?


3


Computer has picked 2


The bottles remaining are: 6


How many you would like to pick up?


4


Computer has picked 1



As per this artificially intelligent program, the Computer should always Win and Never Lose. If User will have to pick up the last beer bottle, then User is Loser and would have to pay the bill.



Computer has picked 1


The bottles remaining are: 1


You will have to pick up thelast..youare loser



Please find below an entire program output from start to end to get an idea how algorithm needs to work





Part 2:Design a UI using Java Swing components, which would look like below. [ need not exactly, but similar].



If you pick up 3 bottles initially and click the button “Pick” to observe how many the Computer picks now, then as per your intelligent algorithm, the Computer needs to pick up anynumberof bottles between 1 and 4 (inclusive), so that at the end, the Computer would WIN. The UI would be as below.




The User must be able to continue the game with Computer, and at every step the remaining bottles need to be displayed appropriately.The numberof remaining bottles would get decreased at each step.




As per this artificially intelligent program, the Computer should always Win and Never Lose. If User will have to pick up the last beer bottle, then User is Loser and would have to pay the bill.







Marking Rubrics































































Criteria



(Unsatisfactory)


Fail




(Satisfactory)


Pass



(Effective)


Credit



(Excellent)


Distinction



(Exceptional)


High Distinction



Delivery


10 marks



No task submitted. Completed less than 50% of the requirements. Not submitted in correct format



Completed between 50-75% of the requirements. Submitted in


correct format




Completed between 75-85% of the requirements. Submitted in correct format



Completed between 85-95% of the requirements. Submitted in correct format



Completed between 95-100% of the requirements. Submitted in correct format



Coding


Standards


10 marks



No name, date, or assignment title included.


Poor use of white


space


(indentation, blank lines). Disorganized and messy.


Poor use of variables (many global variables, ambiguous naming).



Missing information on name, date, or assignment title included.


White space (indentation, blank lines) used properly. Organized work use of variables (many global variables,


ambiguous naming).



Includes name, date, and assignment title.


White space makes


program easy to read. Organized work. Good use of variables (few global


variables,


unambiguous naming).



Includes name, date, and assignment title.


Good use of white space. Organized work. Good use of variables (no global


variables,


unambiguous naming).



Includes name, date, and assignment title. Excellent use of white space.


Creatively organized work.


Excellent use of variables (no global variables,


unambiguous naming).



Documentation


10 marks



No documentation included.



Basic documentation has been completed



Basic documentation has been completed including descriptions of all variables. Purpose is noted for each function.



Clearly


documented including descriptions of all variables. Specific purpose is noted for each function and control structure.



Clearly and effectively


documented including descriptions of all variables.


Specific purpose is noted for each function, control structure, input requirements, and output results.



Runtime


10 marks



Does not execute due to errors. User prompts are misleading or non-existent. No testing has been completed.



Executes with some warning errors.



Executes


without errors. User prompts


contain little information, poor design. Some testing has been completed.



Executes


without errors. User prompts are


understandable, minimum use of symbols or spacing in output.


Thorough testing has been completed



Executes without errors excellent user prompts, good use of symbols, spacing in output.


Thorough and organized testing has been completed and output from test cases is included.



Efficiency


10 marks







A difficult and inefficient solution.



A solution which


provides


some answer but not efficient.



A logical solution that is easy to follow but it is not the most efficient.



Solution is efficient and easy to follow


(i.e. no


confusing tricks).



Solution is efficient, easy to understand, and maintain.



Demonstration


10 marks



Not given or shown irrelevant, incomplete, or ambiguous functionality and features shown and discussed.



Some of the features and functionality are shown and discussed but some are incomplete.



Most of the features and functionality are shown and discussed, are mostly complete.



All the features and functionality are shown and discussed systematically.



All the features and functionality are shown and discussed systematically with additional details.





Submission Instruction



Add all Java files (ending in .java) to a ZIP file. You do not need to zip the entire projectfolder,justthe Java source file(s) (the ‘src’ folder).


Drafted By: Divya Leekha

May 26, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here