This course presents basic concepts and theory of Object Oriented Programming in Java. It covers simple algorithm development using basic control structures, designing methods and utility classes, increasing code reusability and basic strategies on informal testing. Some of the main outcomes of this course include:
- Solve simple algorithmic computing problems using basic control structures and Object-Oriented Techniques.
- Design and implement computer programs based on analysing and modelling requirements.
- Identify and apply basic features of an Object-Oriented programming language through the use of standard Java (Java SE) language constructs and APIs.
- Identify and apply good programming style based on established standards, practices and coding guidelines.
- Devise and apply strategies to test the developed software.
- Explain key concepts of object-oriented programming in Java.
Assignment 1: Menu-driven program
- A skeleton code was provided with
TODO
s - Menu option 1: Calculate the elapsed time of a loop that iterates N times, where N is a very large number from user input.
- Menu option 2: Calculate the area of a triangle with the three side lengths inputed by user.
- Menu option 3: Read a string input then print out the following information: the length of string, the number of alphanumeric letters, the number of whitespaces and the number of tokens (separated by whitespaces).
- No built-in Java
String
and char
helpers is allowed when doing Menu option 3. Students can write their own program without using skeleton code if they wish.
Assignment 2: Employee Management System
- Stage 1: Design classes and logics. This stage focuses on method and data encapsulation, basic problem solving, enhancing code reusability and cohesion.
- Stage 2: Implement system features including listing employees, new employee, displaying employee info, calculating annual bonuses, changing employee boss, promoting and demoting employee position.
- Coding styles and conventions are strictly assessed.
- A skeleton code was provided but students could also write their own code.
Assignment 3: Ferry Booking System
- Students had to use the provided code and work in pair in this assignment.
- Stage 1: Implement StandardBooking class and its methods. This stage just provided a step to practice programming and develop solution for simple problems: allowing vehicles to register for bookings with vehicle info, storing those bookings in memory, adding insurance to bookings, printing and updating booking - vehicle details, calculating booking fees.
- Stage 2: Implement BookingSystem class which provides a Menu for users to interact with the system. Menu has the following options: make booking, display bookings, add insurrance, make special booking (stage 3), record vehicle weight (stage 3).
- Stage 3: Basic Java inheritance with SpecialBooking class implementation. A surcharge will apply on bookings that have overweighted vehicles.
- Stage 4: Incorporate Exception Handling in to the existing system.
On completion of this couse, I have the ideas of basic inheritance and using try-catch
block. I understand the structure of a complex program and an able to design a simple command-line program.