Friday, August 31, 2007

07.CodeRulerReview

Reviewer: Jeffrey Lam
Author of code: Ka Yee Leung


I'm going to reveiw Ka Yee Leung's source code. These are few code violation appare in your source code. The violation problem is around formating convention and naming convention. The following table shows the detail of the violation located.

FileLineViolationComments
MyRuler.java81,83,85,*EJS- 9Use meaningful name
MyRuler.java22EJS- 35Use documentation comments to describe the programming interface, not standardcomments.
MyRuler.java136EJS- 5Newline after end brackets

Wednesday, August 29, 2007

05.CodeRuler

Finally finished. This is my source code
Here


Strategy:
My Knight will split out to catch the enemies and take over their base,
and then my knight will generate many new Knight to take over the rest of enemy base.


Here is my result:

Round1Round2Round3
Jeffrey/Split-up514/782586/785540/591
Jeffrey/Gang-up355/101711/32480/78
Jeffrey/Migrate627/41458/16663/50

I have hard time to make knight move to a direction that what I want and I spend a lot of time on this part


The most important of winning the game is controling your knight movement, if we can group all Knight together and head them to attack one of each enemies castle, then I think the result score would be higher.

Monday, August 27, 2007

OSS Expreience

Overview:

Freecol is like a chess that each player have to do some task for each turn, so player need to think more then that before they move each task. The system is developed by members Richard Roy who is Editorial/Content Writer, and developed with many other developer. The system is java-based, and downloaded from http://sourceforge.net/projects/freecol.

Prime Directive 1:

When accomplish task, system does not have to include every sound, that is the error. But overall is good, the artwork use 2D platform, move is smooth and toolbar is easy to use,very simple, easy to understand.

Here include the manual that explain very detail about the game development and how to play the game.

Prime Directive 2:

This game including a installer ".exe" file to install the game that suit to every PC. Also, its provide a ".jar" file for programmer to development. It has a installer for sourse code that make more easy for everybody.

Prime Directive 3:

This system only include manual about the part of game functions, but it not include the design documentation for other developer. It include the comment in source code. Also, it documented what did they updated for each version.

http://sourceforge.net/project/showfiles.php?group_id=43225&package_id=35488

Tuesday, August 21, 2007

FizzBuzz Assignment

The following codes is my FizzBuzz implementation.

public class FizzBuzz {
public static void main(String[] args) {
int x = 1;
while(x<=100){ if(x%3 == 0){ System.out.print("Fizz\n"); } else if(x%5 == 0){ System.out.print("Buzz\n"); } else if((x%3 == 0) && (x%5 == 0)){ System.out.print("FizzBuzz\n"); } else{ System.out.print(x + "\n"); } x++; } } }

I took one and half hours to finish to implement.
First, I make sure that I can print out numbers from 1 to 100 by using while loop and then debug and run.
Second, I test run IF statment and bound to print multiple of 3 and 5 and then debug and run.
Third, since I implemented the multiple of 3 and 5, then I print the rest of slot as numbers and then debug and run.
I think the most important things is make sure debug and run when did any on each step of implementation, it's help to decrease error appear on large program.