Giter Club home page Giter Club logo

model-1_school-day's Introduction

model-1_school-day

A person has a firstName, lastName & email address.

Teachers & Learners

A teacher teach 1-more subjects. They can only teach subjects they are qualified for.

A Learner needs to be registered for 3 subjects before that can attend any lesson.

Lessons & Subjects

Lessons are for a given Subject. Learners can only attend Lessons for Subjects they are registered for.

A Lesson is taught by a teacher - attended by learners. If there are less than 5 learners attending a Lesson is cancelled. A teacher earn 5 tokens for each lesson teached. A Lesson has a teacher, time and subject. A learner can only attend one lesson at a time.

Notes & Tokens

Each time a learner attend a Lesson they are given notes. If a learner didn't attended a Lesson the can ask other learners who attended a Lesson for the notes.

Attending a Lesson earn a learner 3 tokens. Asking for notes costs 2 tokens. You can only ask for notes if you have enough tokens.

Asking for notes of Subjects you are not registered for costs 5 tokens.

Learners should keep track of Notes they have and if they earned it via lesson attendance or bought it.

At the end of each day a Learners should be able to see what notes and how much tokens they have.

Cafeteria

Tokens can be used at the Cafeteria to Buy Breakfast (4 tokens), Lunch (6 tokens) or an afternoon snack (3 tokens). A drink costs 2 tokens. The Cafeteria manager wants a total of daily tokens received. And also which Person bought what. Teacher gets a 25% discount in the cafeteria once they taught 5 lessons.

The Principal needs to know how many Lessons for each subject is taught on a day and how many Lessons have been cancelled for the day.

Instructions

Create all the Classes needed for this scenario. Wire them all together to model 1 school day.

  • Use the the Java Collection Framework where needed.
  • Focus on 1 school day only.
  • Write JUnit tests. Use TDD! Write your tests first.
  • No persistence is required.

model-1_school-day's People

Contributors

iicwerhelihlek avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.