Homework Assignment: Sudoku Board
|
|
- Raymond Hudson
- 6 years ago
- Views:
Transcription
1 Homework Assignment: Sudoku Board Back Overview of the project This assignment is part of a larger project to create a Sudoku application. Assignment: Sudoku Board Assignment: Sudoku Model Assignment: Sudoku View Assignment: Sudoku Controller and Integration Assignment: Sudoku Serialization (make up assignment) This will take us about a month to complete. Here is a description of the functionality for the whole project. Objectives Working with Java graphic components and containers Abstraction Design considerations Instructions Download the starting point code, SudokuBase.java. Since this is in a named package, make sure that the directory structure for this package has been created. Remember, the JVM will no be able to find the class if the directory structure is incorrect. Here are some notes about this class: The constructor takes the layout dimensions for a Sudoku board. It stores the dimensions in private final variables: rows, columns, size. There are public accessor (getter methods) for these variables. There are some aspects of the code that we have not discussed yet, as examples: the superclass, java.util.observable and the enum type State. Don't panic! We'll be discussing java.util.observable later in the quarter. For this assignment, you can simply ignore the superclass. That is, it would make no difference to your work if the superclass was java.lang.object. An enum, like State, is a new type (like a new primitive type, almost) with the potential values given within the curly braces. There is a simple example of using the enum type in SudokuStub. There are a number of abstract methods which will support basic functionality in the class. We won't need them right now. However, you'll be filling in several of these as part of the work for next week's assignment. Here is a stubbed out subclass that is not abstract, SudokuStub.java. Note the way that the return values were specified for getrowstate, getcolumnstate, and getregionstate. They use the values from the State enum type. Those values are in the scope of the State type (declared within that type), so the s16/hw sudoku_layout.html 1/11
2 Your tasks: names of the values include the type name State. Complete the SudokuBoard.java class. This class draws the basic board for the Sudoku game, indicating the individual cells and the regions. (The rows and columns don't need any specific indication, being obvious if the layout is good.) Add comments to SudokuBase. This includes documentation support, JavaDoc comments. There should be no substantive code changes to SudokuBase; you are only adding comments. This is to insure that you understand the basic functionality you are working with. Implement the SelectedCell.java interface. This interface supports having an "active" cell in the Sudoku Board. Minimal Version SudokuBoard The primary task for this assignment is creating an object that will display the Sudoku board. This display shall render the cells in a square grid. The different regions of the board shall be indicated by a difference in background color. This is a common way to differentiate the regions, as seen in the Background section of the project overview. Use Color.white and Gainsboro for the different region backgrounds. Gainsboro is one of the named colors for web programming. It is #DCDCDC, or rgb(220, 220, 220). The constructor for SudokuBoard takes a SudokuBase as a parameter. From the SudokuBase object, the size and arrangement of the cells and regions can be determined using the public methods getrows and getcolumns. Of course, you can also use the getsize method. The SudokuBoard constructor shall set the preferred size of the SudokuBoard component based on the size of the board. The cell sizes are specified below. To simplify the display, fix the size of the individual cells to 50x50. Drawing borders around the cells will help make the rows and columns easy to see. For example, if there is a one pixel wide border one pixel in from the edge of the cells, the edges are clean. (The alternation of two pixel wide borders between cells and one pixel wide borders at the edges occurs when cell borders abut. This is unattractive.) Notice that this means that there is a two pixel wide margin between the cells. The board can be completed by drawing another line around the entire board such that there is a two pixel wide border at the edges as well. Here is an example of the 2x3 board with these specifications, and a detail view of the upper right corner of the board. s16/hw sudoku_layout.html 2/11
3 Standard Version SelectedCell The SudokuBoard class shall have methods that will get and set the location of the selected cell. The selected cell will be the currently "active" cell. In a later revision of the assignment, the selected cell indicate the cell whose value is to be changed. Indicate the selected cell by a change in the background color of the selected cell. Use a high contrast color. Yellow is a good choice. To support the selected cell, SudokuBoard shall implement the SelectedCell interface. package csc143.sudoku; public interface SelectedCell { public void setselected(int row, int col); s16/hw sudoku_layout.html 3/11
4 } public int getselectedrow(); public int getselectedcolumn(); As you can see, the selected cell can be set programmatically. Also, clicking on a cell shall select that cell. There shall be at most one selected cell within a SudokuBoard. So, when a cell is selected, any previously selected cell is no longer selected. Note: setselected shall perform input validation. If either the row or col parameter contains an unacceptable value, throw an IllegalArgumentException. Challenge Version The challenge version has two facets: keyboard support for changing the selected cell the algorithm to change between two descriptions of a cells location: row/column and region/ordinal Keyboard Support Notes You will need to make the SudokuBoard able to receive focus to get this to work. (What is focus?) If the requested move would move the selected cell past the boundary of the view, sound the system beep instead of moving the selected cell. There is a method java.awt.toolkit.beep that will cause the system beep to sound. Notice that you can request a copy of the toolkit from any graphic object. For more information, see the documentation for java.awt.component. Coordinate Transform There are many different ways to describe the location of a cell within the board. The obvious ones use coordinates. Probably the most obvious is the row and column numbers. Another reasonable choice is the region number and ordinal locator (first, second, third, within the region). Here is a graphic showing these two coordinate schemes for a 2x3 SudokuBoard, row/column in blue, region/ordinal in red. Implement the CoordinateTransform interface in a package private class named s16/hw sudoku_layout.html 4/11
5 csc143.sudoku.translatecoordinates which is included within the SudokuBoard.java file. This class will need to have a constructor; obviously it is not specified in the interface. Testing code Here is some testing code that you can use. SudokuBoardTest.java creates seven standard Sudoku layouts to check your SudokuBoard component. Notice that the testing code is not in the same package as the code it's testing. This is typical. The testing code is not part of that package, that abstraction. It's utility code that helps with the development. For this testing code, we used a simple scheme of adding.test. into the package name. Here are images created by SudokuBoardTest, if SelectedCell is not implemented: s16/hw sudoku_layout.html 5/11
6 s16/hw sudoku_layout.html 6/11
7 s16/hw sudoku_layout.html 7/11
8 s16/hw sudoku_layout.html 8/11
9 s16/hw sudoku_layout.html 9/11
10 Now, if SelectedCell is implemented, the SudokuBoardTest behaves a bit differently. Here is a video showing the behavior of SudokuBoardTest if SelectedCell is implemented. Report At the end of the Sudoku project, you will write a report in which you describe: how you went about starting this project the design decisions you made what works and what doesn t the surprises or problems you encountered while implementing this application the most important thing(s) you learned from this portion of the assignment what you would do differently next time The design decisions for the second question should include the rationale for such things as: creating a field (why it can't be a local variable), giving a field an access level other than private (why it is directly shared rather than having set and get methods), giving a method an access level other than public or private (why the intermediate access level), essentially, anything that isn't typical "best practices" in programming. The last question, "What would you do differently next time?" is asking about the general principles of software design, implementation, and testing that you learned in the process. It is not asking for specific aspects of this particular project that you would approach differently. The reason for this question is because the theorists say that one of the primary ways we learn is when we reflect upon our experiences. The homework for this class should be a learning experience. Since this is a larger project, it is imperative that you have some notes about this early work. For this part of the assignment, submit your notes for this part of the project. The goal is to have something that you can use to write the written report at the end of the project. Deliverable for the report notes: ASCII text file containing notes. s16/hw sudoku_layout.html 10/11
11 Deliverables Three files: The updated SudokuBoard.java. The updated SudokuBase.java files. JavaDoc comments added. A text file with the notes for the report. (plus algorithm for Challenge level) Note, when you submit the two source code files, these classes are still in the csc143.sudoku package. Do not submit an archive file format, e.g..jar,.zip,.rar, etc. Grading Rubric Functionality: (8 points) Minimal: 5 points SudokuBoard compiles and runs with SudokuBoardTest generates board of the appropriate dimensions appropriate region is arrangement for SudokuBoard Standard: 3 additional points implementation for SelectedCell selected cell displays with a highlight background color selected cell can be set programmatically selected cell can be set by mouse Challenge: 2 additional points algorithm is provided to translate cell coordinates between row columns and region ordinal implemented in SudokuBoard selected cell can be set by keyboard Style: (2 points) Appropriate formatting (vertical alignment, indentation, uniform brace placement) Reasonable naming Documentation: (5 points) JavaDoc comments for public/protected resources with appropriate tags Standard comments (// or /* */) for private or package private resources JavaDoc runs without warnings ASCII text file for report, with appropriate header giving your name and this assignment name and number Reasonable information is included in the report notes Back s16/hw sudoku_layout.html 11/11
CS 201 Advanced Object-Oriented Programming Lab 6 - Sudoku, Part 2 Due: March 10/11, 11:30 PM
CS 201 Advanced Object-Oriented Programming Lab 6 - Sudoku, Part 2 Due: March 10/11, 11:30 PM Introduction to the Assignment In this lab, you will finish the program to allow a user to solve Sudoku puzzles.
More informationCS 170 Java Programming 1. Week 12: Creating Your Own Types
CS 170 Java Programming 1 Week 12: Creating Your Own Types What s the Plan? Topic 1: A Little Review Work with loops to process arrays Write functions to process 2D Arrays in various ways Topic 2: Creating
More informationCIS 121 Data Structures and Algorithms with Java Spring 2018
CIS 121 Data Structures and Algorithms with Java Spring 2018 Homework 2 Thursday, January 18 Due Monday, January 29 by 11:59 PM 7 Required Problems (85 points), and Style and Tests (15 points) DO NOT modify
More informationSlide 1 CS 170 Java Programming 1 Multidimensional Arrays Duration: 00:00:39 Advance mode: Auto
CS 170 Java Programming 1 Working with Rows and Columns Slide 1 CS 170 Java Programming 1 Duration: 00:00:39 Create a multidimensional array with multiple brackets int[ ] d1 = new int[5]; int[ ][ ] d2;
More informationJava Style Guide. 1.0 General. 2.0 Visual Layout. Dr Caffeine
September 25, 2002 Java Style Guide Dr Caffeine This document defines the style convention the students must follow in submitting their programs. This document is a modified version of the document originally
More informationCMPSC 111 Introduction to Computer Science I Fall 2016 Lab 8 Assigned: October 26, 2016 Due: November 2, 2016 by 2:30pm
1 CMPSC 111 Introduction to Computer Science I Fall 2016 Lab 8 Assigned: October 26, 2016 Due: November 2, 2016 by 2:30pm Objectives To enhance your experience with designing and implementing your own
More informationCS Fall Homework 5 p. 1. CS Homework 5
CS 235 - Fall 2015 - Homework 5 p. 1 Deadline: CS 235 - Homework 5 Due by 11:59 pm on Wednesday, September 30, 2015. How to submit: Submit your files using ~st10/235submit on nrs-projects, with a homework
More informationClasses, interfaces, & documentation. Review of basic building blocks
Classes, interfaces, & documentation Review of basic building blocks Objects Data structures literally, storage containers for data constitute object knowledge or state Operations an object can perform
More information5.6.1 The Special Variable this
ALTHOUGH THE BASIC IDEAS of object-oriented programming are reasonably simple and clear, they are subtle, and they take time to get used to And unfortunately, beyond the basic ideas there are a lot of
More informationBe sure check the official clarification thread for corrections or updates to this document or to the distributed code.
Com S 228 Spring 2011 Programming Assignment 1 Part 1 (75 points): Due at 11:59 pm, Friday, January 28 Part 2 (225 points): Due at 11:59 pm, Monday, February 7 This assignment is to be done on your own.
More informationCS 11 java track: lecture 3
CS 11 java track: lecture 3 This week: documentation (javadoc) exception handling more on object-oriented programming (OOP) inheritance and polymorphism abstract classes and interfaces graphical user interfaces
More informationDocumentation Requirements Computer Science 2334 Spring 2016
Overview: Documentation Requirements Computer Science 2334 Spring 2016 These requirements are based on official Java coding conventions but have been adapted to be more appropriate to an academic environment.
More informationCS 251 Intermediate Programming Coding Standards
CS 251 Intermediate Programming Coding Standards Brooke Chenoweth University of New Mexico Fall 2018 CS-251 Coding Standards All projects and labs must follow the great and hallowed CS-251 coding standards.
More informationTips from the experts: How to waste a lot of time on this assignment
Com S 227 Spring 2018 Assignment 1 100 points Due Date: Friday, September 14, 11:59 pm (midnight) Late deadline (25% penalty): Monday, September 17, 11:59 pm General information This assignment is to be
More informationOur second exam is Monday, April 3. Note that it will not be possible to get all the homework submissions graded before the exam.
Com S 227 Spring 2017 Assignment 3 300 points Due Date:, Wednesday, March 29 11:59 pm (midnight) Late deadline (25% penalty): Thursday, March 30, 11:59 pm General information This assignment is to be done
More informationOur second exam is Thursday, November 10. Note that it will not be possible to get all the homework submissions graded before the exam.
Com S 227 Fall 2016 Assignment 3 300 points Due Date: Wednesday, November 2, 11:59 pm (midnight) Late deadline (25% penalty): Thursday, November 2, 11:59 pm General information This assignment is to be
More informationProgram 12 - Spring 2018
CIST 1400, Introduction to Computer Programming Programming Assignment Program 12 - Spring 2018 Overview of Program Earlier this semester, you have written programs that read and processed dates in various
More informationThis assignment requires that you complete the following tasks (in no particular order).
Construction Objectives The objectives of this assignment are: (1) Implement your FCS design with high-quality code and thorough unit tests (2) Gain experience doing a task breakdown (3) Gain experience
More informationIntroduction. Inserting and Modifying Tables. Word 2010 Working with Tables. To Insert a Blank Table: Page 1
Word 2010 Working with Tables Introduction Page 1 A table is a grid of cells arranged in rows and columns. Tables can be customized and are useful for various tasks such as presenting text information
More informationCS 201 Advanced Object-Oriented Programming Lab 5 - Sudoku, Part 1 Due: March 3/4, 11:30 PM
CS 201 Advanced Object-Oriented Programming Lab 5 - Sudoku, Part 1 Due: March 3/4, 11:30 PM Introduction to the Assignment This is the 1 st part of a 2 week lab. When done, you will have a game that allows
More informationWrite for your audience
Comments Write for your audience Program documentation is for programmers, not end users There are two groups of programmers, and they need different kinds of documentation Some programmers need to use
More informationTips from the experts: How to waste a lot of time on this assignment
Com S 227 Spring 2018 Assignment 1 80 points Due Date: Friday, February 2, 11:59 pm (midnight) Late deadline (25% penalty): Monday, February 5, 11:59 pm General information This assignment is to be done
More informationCS 134 Programming Exercise 9:
CS 134 Programming Exercise 9: Nibbles Objective: To gain experience working with 2 dimensional arrays. The Problem Nibbles is a snake. Nibbles moves around a field, looking for food. Unfortunately, Nibbles
More informationCS1004: Intro to CS in Java, Spring 2005
CS1004: Intro to CS in Java, Spring 2005 Lecture #13: Java OO cont d. Janak J Parekh janak@cs.columbia.edu Administrivia Homework due next week Problem #2 revisited Constructors, revisited Remember: a
More informationObjective: Class Activities
Objective: A Pivot Table is way to present information in a report format. The idea is that you can click drop down lists and change the data that is being displayed. Students will learn how to group data
More informationCS 177 Recitation. Week 8 Methods
CS 177 Recitation Week 8 Methods Questions? Announcements Project 3 milestone due next Thursday 10/22 9pm Turn in with: turnin c cs177=xxxx p project3m Project3.java Make sure you turn in to project3m
More informationTips from the experts: How to waste a lot of time on this assignment
Com S 227 Spring 2017 Assignment 1 80 points Due Date: Thursday, February 2, 11:59 pm (midnight) Late deadline (25% penalty): Friday, February 3, 11:59 pm General information This assignment is to be done
More informationCS Exam 1 Review Suggestions
CS 235 - Fall 2015 - Exam 1 Review Suggestions p. 1 last modified: 2015-09-30 CS 235 - Exam 1 Review Suggestions You are responsible for material covered in class sessions, lab exercises, and homeworks;
More informationCS Problem Solving and Object-Oriented Programming
CS 101 - Problem Solving and Object-Oriented Programming Lab 5 - Draw a Penguin Due: October 28/29 Pre-lab Preparation Before coming to lab, you are expected to have: Read Bruce chapters 1-3 Introduction
More informationSummary. Recursion. Overall Assignment Description. Part 1: Recursively Searching Files and Directories
Recursion Overall Assignment Description This assignment consists of two parts, both dealing with recursion. In the first, you will write a program that recursively searches a directory tree. In the second,
More informationTitle and Modify Page Properties
Dreamweaver After cropping out all of the pieces from Photoshop we are ready to begin putting the pieces back together in Dreamweaver. If we were to layout all of the pieces on a table we would have graphics
More informationCS161: Introduction to Computer Science Homework Assignment 10 Due: Monday 11/28 by 11:59pm
CS161: Introduction to Computer Science Homework Assignment 10 Due: Monday 11/28 by 11:59pm Many cable packages come with a search interface that let s you search for a show or movie by typing the name
More informationSchoolwires Editor Best Practices. Schoolwires Centricity2
Schoolwires Editor Best Practices Schoolwires Centricity2 Schoolwires Centricity2 Editor Best Practices Table of Contents Introduction... 1 Practices for All Browsers... 2 Bullets Left Justify Bullets...
More informationINFS 2150 / 7150 Intro to Web Development / HTML Programming
XP Objectives INFS 2150 / 7150 Intro to Web Development / HTML Programming Designing a Web Page with Tables Create a text table Create a table using the , , and tags Create table headers
More informationThe first program: Little Crab
Chapter 2 The first program: Little Crab topics: concepts: writing code: movement, turning, reacting to the screen edges source code, method call, parameter, sequence, if-statement In the previous chapter,
More informationCOP 3330 Final Exam Review
COP 3330 Final Exam Review I. The Basics (Chapters 2, 5, 6) a. comments b. identifiers, reserved words c. white space d. compilers vs. interpreters e. syntax, semantics f. errors i. syntax ii. run-time
More informationMicrosoft Word Part I Reference Manual
Microsoft Word 2002 Part I Reference Manual Instructor: Angela Sanderson Computer Training Coordinator Updated by: Angela Sanderson January 11, 2003 Prepared by: Vi Johnson November 20, 2002 THE WORD SCREEN
More informationQuarter II Word Processing
Quarter II Word Processing Module III Understanding MS Word 2007 This module will walk you through the fundamentals of word processing software and prepare you to learn, perform, and make you understand
More information16-Dec-10. Consider the following method:
Boaz Kantor Introduction to Computer Science IDC Herzliya Exception is a class. Java comes with many, we can write our own. The Exception objects, along with some Java-specific structures, allow us to
More informationCS 315 Software Design Homework 1 First Sip of Java Due: Sept. 10, 11:30 PM
CS 315 Software Design Homework 1 First Sip of Java Due: Sept. 10, 11:30 PM Objectives The objectives of this assignment are: to get your first experience with Java to become familiar with Eclipse Java
More informationYou Can Make a Difference! Due April 11/12 (Implementation plans due in class on 4/9)
You Can Make a Difference! Due April 11/12 (Implementation plans due in class on 4/9) In last week s lab, we introduced some of the basic mechanisms used to manipulate images in Java programs. Now, we
More informationC++ Style Guide. 1.0 General. 2.0 Visual Layout. 3.0 Indentation and Whitespace
C++ Style Guide 1.0 General The purpose of the style guide is not to restrict your programming, but rather to establish a consistent format for your programs. This will help you debug and maintain your
More informationChapter 6 Introduction to Defining Classes
Introduction to Defining Classes Fundamentals of Java: AP Computer Science Essentials, 4th Edition 1 Objectives Design and implement a simple class from user requirements. Organize a program in terms of
More informationCSE 143: Computer Programming II Spring 2015 HW7: 20 Questions (due Thursday, May 28, :30pm)
CSE 143: Computer Programming II Spring 2015 HW7: 20 Questions (due Thursday, May 28, 2015 11:30pm) This program focuses on binary trees and recursion. Turn in the following files using the link on the
More informationSchool of Computer Science CPS109 Course Notes Set 7 Alexander Ferworn Updated Fall 15 CPS109 Course Notes 7
CPS109 Course Notes 7 Alexander Ferworn Unrelated Facts Worth Remembering The most successful people in any business are usually the most interesting. Don t confuse extensive documentation of a situation
More informationCS Homework 10 p. 1. CS Homework 10
CS 111 - Homework 10 p. 1 Deadline 11:59 pm on Friday, December 2, 2016 How to submit Each time you would like to submit your work: CS 111 - Homework 10 If your files are not already on nrs-labs, be sure
More informationObject-Oriented Programming (OOP) Basics. CSCI 161 Introduction to Programming I
Object-Oriented Programming (OOP) Basics CSCI 161 Introduction to Programming I Overview Chapter 8 in the textbook Building Java Programs, by Reges & Stepp. Review of OOP History and Terms Discussion of
More informationCS 170 Java Programming 1. Week 13: Classes, Testing, Debugging
CS 170 Java Programming 1 Week 13: Classes, Testing, Debugging What s the Plan? Short lecture for makeup exams Topic 1: A Little Review How to create your own user-defined classes Defining instance variables,
More informationPractical 2: Ray Tracing
2017/2018, 4th quarter INFOGR: Graphics Practical 2: Ray Tracing Author: Jacco Bikker The assignment: The purpose of this assignment is to create a small Whitted-style ray tracer. The renderer should be
More informationRegis University CC&IS CS310 Data Structures Programming Assignment 2: Arrays and ArrayLists
Regis University CC&IS CS310 Data Structures Programming Assignment 2 Arrays and ArrayLists Problem Scenario The real estate office was very impressed with your work from last week. The IT director now
More informationCSE 143: Computer Programming II Summer 2015 HW6: 20 Questions (due Thursday, August 13, :30pm)
CSE 143: Computer Programming II Summer 2015 HW6: 20 Questions (due Thursday, August 13, 2015 11:30pm) This assignment focuses on binary trees and recursion. Turn in the following files using the link
More informationCS 351 Design of Large Programs Coding Standards
CS 351 Design of Large Programs Coding Standards Brooke Chenoweth University of New Mexico Spring 2018 CS-351 Coding Standards All projects and labs must follow the great and hallowed CS-351 coding standards.
More informationEECS168 Exam 3 Review
EECS168 Exam 3 Review Exam 3 Time: 2pm-2:50pm Monday Nov 5 Closed book, closed notes. Calculators or other electronic devices are not permitted or required. If you are unable to attend an exam for any
More informationWeek 5 Creating a Calendar. About Tables. Making a Calendar From a Table Template. Week 5 Word 2010
Week 5 Creating a Calendar About Tables Tables are a good way to organize information. They can consist of only a few cells, or many cells that cover several pages. You can arrange boxes or cells vertically
More informationCom S 227 Spring 2018 Assignment points Due Date: Thursday, September 27, 11:59 pm (midnight) "Late" deadline: Friday, September 28, 11:59 pm
Com S 227 Spring 2018 Assignment 2 200 points Due Date: Thursday, September 27, 11:59 pm (midnight) "Late" deadline: Friday, September 28, 11:59 pm (Remember that Exam 1 is MONDAY, October 1.) General
More informationCS 215 Software Design Homework 3 Due: February 28, 11:30 PM
CS 215 Software Design Homework 3 Due: February 28, 11:30 PM Objectives Specifying and checking class invariants Writing an abstract class Writing an immutable class Background Polynomials are a common
More informationCom S 227 Spring 2018 Assignment points Due Date: Wednesday, March 28, 11:59 pm (midnight) "Late" deadline: Thursday, March 29, 11:59 pm
Com S 227 Spring 2018 Assignment 3 300 points Due Date: Wednesday, March 28, 11:59 pm (midnight) "Late" deadline: Thursday, March 29, 11:59 pm General information This assignment is to be done on your
More informationCS112 Lecture: Defining Instantiable Classes
CS112 Lecture: Defining Instantiable Classes Last revised 2/3/05 Objectives: 1. To describe the process of defining an instantiable class 2. To discuss public and private visibility modifiers. Materials:
More informationCreating Web Pages with SeaMonkey Composer
1 of 26 6/13/2011 11:26 PM Creating Web Pages with SeaMonkey Composer SeaMonkey Composer lets you create your own web pages and publish them on the web. You don't have to know HTML to use Composer; it
More informationAutoCollage 2008 makes it easy to create an AutoCollage from a folder of Images. To create an AutoCollage:
Page 1 of 18 Using AutoCollage 2008 AutoCollage 2008 makes it easy to create an AutoCollage from a folder of Images. To create an AutoCollage: 1. Click on a folder name in the Image Browser. 2. Once at
More informationProductivity! Feature Matrix
Features Code Generation Tools JBuilderX and Productivity! Std Pro JBuilderX Delegate.Insight - provides an easy way to generate methods, which implementations are delegated to another object (delegate).
More informationProgramming Exercise
Programming Exercise Nibbles Objective: To gain experience working with 2 dimensional arrays. The Problem Nibbles is a snake. Nibbles moves around a field, looking for food. Unfortunately, Nibbles is not
More informationLearning Word The ABCs of Microsoft Word. 8/19/2015 The Computor Tutor 1
Learning Word 2013 The ABCs of Microsoft Word 8/19/2015 The Computor Tutor 1 The Program Open Word Margins are preset to Normal, 1 inch for Top, Bottom, Right & Left; change by clicking on Page Layout
More informationAbout this sample exam:
About this sample exam: You may and SHOULD work through this exam yourself and discuss you answers with others. To find out the right answers to questions, type in the code to a compiler and run it. You
More informationCPS122 Lecture: Defining a Class
Objectives: CPS122 Lecture: Defining a Class last revised January 14, 2016 1. To introduce structure of a Java class 2. To introduce the different kinds of Java variables (instance, class, parameter, local)
More information3. NetBeans IDE 6.0. Java. Fall 2009 Instructor: Dr. Masoud Yaghini
3. NetBeans IDE 6.0 Java Fall 2009 Instructor: Dr. Masoud Yaghini Outline Installing the NetBeans IDE First NetBeans IDE Project IDE Windows Source Editor Customizing the IDE References Installing the
More informationPOWERPOINT Build a Presentation to Remember
POWERPOINT 2007 Build a Presentation to Remember Microsoft Office 2007 TABLE OF CONTENTS DOCUMENT THEMES... 1 THEMES... 1 COLOR SETS... 1 FONT SETS... 1 MASTER SLIDES... 2 USING THEMES IN THE SLIDE MASTER...
More informationISY00245 Principles of Programming. Module 7
ISY00245 Principles of Programming Module 7 Module 7 Loops and Arrays Introduction This week we have gone through some of the concepts in your lecture, and will be putting them in to practice (as well
More informationCS 134 Programming Exercise 2:
CS 134 Programming Exercise 2: Dirty Laundry Objective: To gain experience using conditionals. The Scenario. One thing some students have to figure out for the first time when they come to college is how
More informationMathematics/Science Department Kirkwood Community College. Course Syllabus. Computer Science CSC142 1/10
Mathematics/Science Department Kirkwood Community College Course Syllabus Computer Science CSC142 Bob Driggs Dean Cate Sheller Instructor 1/10 Computer Science (CSC142) Course Description Introduces computer
More informationCS112 Lecture: Defining Classes. 1. To describe the process of defining an instantiable class
CS112 Lecture: Defining Classes Last revised 2/3/06 Objectives: 1. To describe the process of defining an instantiable class Materials: 1. BlueJ SavingsAccount example project 2. Handout of code for SavingsAccount
More informationIntermediate Microsoft Office 2016: Word
Intermediate Microsoft Office 2016: Word Updated January 2017 Price: $1.20 Lesson 1: Setting Margins A margin is the distance from the text to the paper s edge. The default setting is 1 all around the
More informationUsing the API: Introductory Graphics Java Programming 1 Lesson 8
Using the API: Introductory Graphics Java Programming 1 Lesson 8 Using Java Provided Classes In this lesson we'll focus on using the Graphics class and its capabilities. This will serve two purposes: first
More informationIntroduction. Using Indents and Tab Stops. Google Documents Using Indents, Tabs, and Lists. Indenting Text. Page 1
Google Documents Using Indents, Tabs, and Lists Introduction Page 1 Indenting and lists are a great way to draw attention to important areas of your document. There are several ways in Google Documents
More informationFrontPage 98 Quick Guide. Copyright 2000 Peter Pappas. edteck press All rights reserved.
Master web design skills with Microsoft FrontPage 98. This step-by-step guide uses over 40 full color close-up screen shots to clearly explain the fast and easy way to design a web site. Use edteck s QuickGuide
More informationCSE 142 Su 04 Computer Programming 1 - Java. Objects
Objects Objects have state and behavior. State is maintained in instance variables which live as long as the object does. Behavior is implemented in methods, which can be called by other objects to request
More informationACORN.COM CS 1110 SPRING 2012: ASSIGNMENT A1
ACORN.COM CS 1110 SPRING 2012: ASSIGNMENT A1 Due to CMS by Tuesday, February 14. Social networking has caused a return of the dot-com madness. You want in on the easy money, so you have decided to make
More informationCS 251 Intermediate Programming Methods and Classes
CS 251 Intermediate Programming Methods and Classes Brooke Chenoweth University of New Mexico Fall 2018 Methods An operation that can be performed on an object Has return type and parameters Method with
More informationCS 251 Intermediate Programming Methods and More
CS 251 Intermediate Programming Methods and More Brooke Chenoweth University of New Mexico Spring 2018 Methods An operation that can be performed on an object Has return type and parameters Method with
More informationRev. C 11/09/2010 Downers Grove Public Library Page 1 of 41
Table of Contents Objectives... 3 Introduction... 3 Excel Ribbon Components... 3 Office Button... 4 Quick Access Toolbar... 5 Excel Worksheet Components... 8 Navigating Through a Worksheet... 8 Making
More informationRule 1-3: Use white space to break a function into paragraphs. Rule 1-5: Avoid very long statements. Use multiple shorter statements instead.
Chapter 9: Rules Chapter 1:Style and Program Organization Rule 1-1: Organize programs for readability, just as you would expect an author to organize a book. Rule 1-2: Divide each module up into a public
More informationInheritance, cont. Notes Chapter 6 and AJ Chapters 7 and 8
Inheritance, cont. Notes Chapter 6 and AJ Chapters 7 and 8 1 Preconditions and Inheritance precondition what the method assumes to be true about the arguments passed to it inheritance (is-a) a subclass
More information12/22/11. } Rolling a Six-Sided Die. } Fig 6.7: Rolling a Six-Sided Die 6,000,000 Times
} Rolling a Six-Sided Die face = 1 + randomnumbers.nextint( 6 ); The argument 6 called the scaling factor represents the number of unique values that nextint should produce (0 5) This is called scaling
More informationProgram Correctness and Efficiency. Chapter 2
Program Correctness and Efficiency Chapter 2 Chapter Objectives To understand the differences between the three categories of program errors To understand the effect of an uncaught exception and why you
More informationCSE wi Midterm Exam 2/8/18. Name UW ID #
Name UW ID # There are 11 questions worth a total of 120 points. Please budget your time so you get to all of the questions. Keep your answers brief and to the point. The exam is closed book, closed notes,
More informationUnit 5: More on Classes/Objects Notes
Unit 5: More on Classes/Objects Notes AP CS A The Difference between Primitive and Object/Reference Data Types First, remember the definition of a variable. A variable is a. So, an obvious question is:
More informationBlock I Unit 2. Basic Constructs in Java. AOU Beirut Computer Science M301 Block I, unit 2 1
Block I Unit 2 Basic Constructs in Java M301 Block I, unit 2 1 Developing a Simple Java Program Objectives: Create a simple object using a constructor. Create and display a window frame. Paint a message
More information7. C++ Class and Object
7. C++ Class and Object 7.1 Class: The classes are the most important feature of C++ that leads to Object Oriented programming. Class is a user defined data type, which holds its own data members and member
More informationLab 4: Super Sudoku Solver CSCI 2101 Fall 2017
Due: Wednesday, October 18, 11:59 pm Collaboration Policy: Level 1 Group Policy: Pair-Optional Lab 4: Super Sudoku Solver CSCI 2101 Fall 2017 In this week s lab, you will write a program that can solve
More informationQUIZ Friends class Y;
QUIZ Friends class Y; Is a forward declaration neeed here? QUIZ Friends QUIZ Friends - CONCLUSION Forward (a.k.a. incomplete) declarations are needed only when we declare member functions as friends. They
More informationGRAPHICS & INTERACTIVE PROGRAMMING. Lecture 1 Introduction to Processing
BRIDGES TO COMPUTING General Information: This document was created for use in the "Bridges to Computing" project of Brooklyn College. This work is licensed under the Creative Commons Attribution-ShareAlike
More informationJava Programming. Computer Science 112
Java Programming Computer Science 112 Review: Problem solving Class 4 is the Whole Point of Programming. Is there any particular one you'd like to go through? If you are desperately confused still, now
More informationUnderstanding Word Processing
Understanding Word Processing 3.0 Introduction In this chapter you are going to learn how to create a simple memo or note or a complex and complicated multi column business document using word processing
More informationEducational Fusion. Implementing a Production Quality User Interface With JFC
Educational Fusion Implementing a Production Quality User Interface With JFC Kevin Kennedy Prof. Seth Teller 6.199 May 1999 Abstract Educational Fusion is a online algorithmic teaching program implemented
More informationDecision Logic: if, if else, switch, Boolean conditions and variables
CS 1044 roject 4 Summer I 2007 Decision Logic: if, if else, switch, Boolean conditions and variables This programming assignment uses many of the ideas presented in sections 3 through 5 of the course notes,
More information1 Shyam sir JAVA Notes
1 Shyam sir JAVA Notes 1. What is the most important feature of Java? Java is a platform independent language. 2. What do you mean by platform independence? Platform independence means that we can write
More information} Each object in a Java program has an identifier (name) } This includes:
Class #05: More about Objects and Methods Software Design I (CS 120): M. Allen, 11 Sept. 2018 Important Java Syntax I: Identifiers Each object in a Java program has an identifier (name) This includes:
More informationChapter 4 Java Language Fundamentals
Chapter 4 Java Language Fundamentals Develop code that declares classes, interfaces, and enums, and includes the appropriate use of package and import statements Explain the effect of modifiers Given an
More informationCSci 1113, Fall 2015 Lab Exercise 11 (Week 13): Discrete Event Simulation. Warm-up. Stretch
CSci 1113, Fall 2015 Lab Exercise 11 (Week 13): Discrete Event Simulation It's time to put all of your C++ knowledge to use to implement a substantial program. In this lab exercise you will construct a
More information