Edinboro University

CSCI 374 Web Development
Spring 2020


Resources You'll need:


Week
Starting

 
1/13

Introduction to the course

  • Go over syllabus
  • What you'll learn
  • What you need
  • Assignments
  • Grading
  • Expectations
  • Lab time
  • Edinboro Network
  • Take roll

Chapter 1

 

1/20

Chapter 2

1/27

Chapter 3

2/3

  • Continue Chapter 3
  • Do some of the problems in the back of Chapter 3 as prep for the chapter 3 assignment.
2/10

Chapter 4


2/17

 

Chapter 4

2/24

Chapter 5


3/2
  • Talk about the database functions of the Candy Store
  • #21 Add a back button to the update activity

Chapter 6

 

3/9 Spring Break
3/16

Extended Break due to moving all courses on line

3/23

Helpful hints for the Trivia game

  • Adding functionality to the database (vs. the candy store)
  • how to shuffle questions
  • how to shuffle answers
  • Keep track of number of right and wrong answers
  • Add more styles to the buttons
  • Add a launcher icon

Discuss the next assignment

Chapter 6: Managing Orientation

3/30

In-Class Exercise

Let's do #24 page 247 in class and possibly on Thursday. We'll take our old tip calculator and make it so it looks good horizontal also. Let's not worry about the number of guests options

Let's do the 2 XML file option. Here's my solution:

Verticle Tip Calc Horizontal Tip Calc

4/6

Chapter 7

 

 

4/13

Chapter 8

Chapter 9

 

4/20

Chapter 10

Chapter 11

Chapter 12

 

Final Exam Period

Tuesday the 28th @ 10:15 am



 

     


Assignments

Please put your Name at the end of your project name ex.) "Caloire_Counter_Dale_Jones"

Due Date Description
HW-1
1/24

#11 and #12 Page 38.

HW-2
2/6

Calorie Counter

#30 Page 85

Compare to https://caloriecontrol.org/healthy-weight-tool-kit/get-moving-calculator/

Calories Burned = (MET value) * (Weight in kg) * (Hours Spent)

Met Values:

  • Aerobics: 7.3
  • Bicycling: 7.5
  • Dancing: 5
  • Running: 9.8
  • Swimming: 6
  • Walking: 4.3

1kg = 2.2 lbs.

Calorie Counter Solution Calorie Counter Solution Calorie Counter Solution

 

HW-3

2/13

Simple BlackJack

#30 Page 126

Remember with this assignment don't use XML to create your layout. Build this via Java code in your MainActivity.java

Note the "busted" below on the 3rd image when the player goes over 21.

Simple Blackjack 1 Simple Blackjack 2 Simple Blackjack 3

 

HW-4

2/25

Currency Converter

#31 page 172 -

  • Use XML to design the screen if you want (vs. programatically as in the previous assignment).
  • You can take parts off of the Mortgage Calculator or the Temperature Converter we did in class
  • Look at examples below. I based this off of what we designed in class. This a total of 2 screens, the last 2 screen shots are of the same page.
  • Currency Converter ratios:
    • 0.93 Euro to a 1 dollar
    • 7.02 Yuan to 1 dollar
    • 0.78 pounds sterling to 1 dollar
    • 71.88 Rupees to one dollar
    • 112.07 Yen to one dollar

 

 

HW-5

3/17

 

Trivia Game

#29, #30, and # 31 Page 218 & 219

Write a quiz app using SQLite

We'll discuss design in class, but I envision a screen where the player presses a button and it randomly selects a question, puts it on the screen with several answers, the player selects an answer and the app tells if its correct or not.

Randomly select a question from the database

I think you need to programatically build the question page, this will allow for a new question easier.

Then add a ADD, EDIT, and DELETE feature like the candy store app we did in class. Where the user can add,edit or delete questions and their answers.

You need a table with possibly 6 fields:

  • ID
  • Question
  • Answer1
  • Answer2
  • Answer3
  • Answer4

I recommend you design your table so that Answer 1 holds the correct answer.  When you display a question on the screen you'll need to scramble the answers.  

Have a "Toast" pop up telling them if their selection was correct or not.

If users hits incorrect answer then change the background color of the correct answer to let them know which was the correct answer.

Need a button to move the the next question

Use menu/toolbar to display the links to

  • Add
  • Edit
  • Delete

Screen schots of my Trivia Game Solution (I made state capitol trivia)

Notes:

The last screen is the delete question screen where you just tap the qustion to delete it, like the candy store app. I also only have the Add, Delete, and Edit menu items on the initial page. I also pre-load the table with 17 state triva questions in the MainActivity.java, I just repeatdely call the add record from the database class and hard code the questions and answers. I blank out the table 1st so it doesn't keep adding those questions every time its played.

Start Screen  Initial Screen  Correct Answer  Wrong Answer  End  Add Question  Edit Question  Delete Question

 

HW-6

Game of NIM

Let's do # 22 on page 246. The computer displays a random number of scicks from 10 to 20. Then you take turns, either with another player or with the comptuer, picking up 1, 2, or 3 sticks. You win by making the other player be the last to pick up a stick.

Initial NIM Screen 2nd NIM Screen 2nd NIM Screen 2nd NIM Screen

Against the Computer:
2nd NIM Screen 2nd NIM Screen 2nd NIM Screen Computer Won Screen Player Beat Computer

Adjusted for Landscape:
Here I made 2 new XML files for the initial play screen and the in-play screen. I used a horizontal linear layout and adjusted the margins for the initial screen. For the play screen I just adjusted the width of the buttons.
2nd NIM Screen 2nd NIM Screen

HW-7


**** No New Assignments the rest of the semester!! ****

Final Project

Some Ideas

  • Concentration/Memory → Camden Stover
  • Pass the Pigs → Jozef Jankowiak
  • Blackjack → Ian Warner (Look at #33 p. 296 for some interface ideas)
  • "Space Invaders" → Austin Oaks
  • Tile Puzzle Game (# 29 page 296) → Charis Larson