Activities - Homework Project
Record your participation in Piazza clicker question Lesson1 Q1
We are going to start at the beginning and set up Hw1a draft together
- read the assignment to see what we need to do
- start Bluej,
- make a project.
- in the folder cs46a/homeworks/hw01/draft.
- call it hw1a_first_draft
- make a new class.
- copy in the code form Codecheck
- add your code
- compile
- run by right clicking on FirstProgram and choosing
void main(String[] args)
- copy/paste the code into Codecheck
- Click submit
- Download the report.
- I suggest adding _draft before the extension. (.signed.zip). Do not add another dot (.)
- upload report to Canvas - you will need to upload it again with the other two files
Activity - Graphics
Record your participation in Piazza clicker question Lesson1 Q2
You will need to draw a picture for the draft for 1c.
- Discussed in the Hortstmann videos
Let's create an application to draw a Picture with the Horstmann graphics package
- download the file redwood.zip from here
- unzip the file
- double click on package.bluej
- open RedwoodViewer
- create Picture object in the main method
- Picture tree = new Picture("redwood.png");
- draw picture object
- compile
- run
- look in the folder for another picture
- change the code to use the other image
Activity - Finding Syntax Errors
Record your participation in Piazza clicker question Lesson1 Q3
One important skill is to be able to decipher syntax error messages
Let's practice
- download the test project, test.zip from here
- double click on package.bluej
- open the Test class
- compile
- what does the error say? what do you think it means?
- fix the error
- compile and run
- remove the // (comment symbol) from the next line
- compile
- what does the error say? what do you think it means?