Archive

Posts Tagged ‘java’

C2005 Object Oriented Programming in Java Term 2 2008 Assignment

February 12th, 2009

Hi everyone!

This is the third and the last post for the first part of IADIC assignment series. This time I will post about the assignment from C2005 OOP in Java that I take in Term 2 2008. This module basically teach about how to make and use objects in Java in a very simple way, so don’t expect to get an advanced Java technique here as it is a very basic Java skill that is taught by this module.

The assignment that I get in Term 2 2008 asked me to make a simple program for an electronic shop.

here is the questions:
Click here to read the full post…

admin Education, IADIC, Informatics , , , ,

C1022 Introduction to Java Term 1 2008 assignment

February 1st, 2009

Hi! :)
This time I will post the assignment that I get for C1022 Introduction to Java module in Term 1 2008.

SECTION A

A1.      Write Java statements to accomplish each of the following:

a)      Declare a variable ‘reply’ to be of type char.

char reply;

b)      To compare the contents of both variables ‘pass’ and ‘word’ of type String.

pass.compareTo (word) > 0;

pass.compareTo (word) == 0;

pass.compareTo (word) < 0;

pass.compareTo (word) > 0;

pass.equals (word);

pass.equalsIgnoreCase (word);

c)      To assign a float value 2.5 to a variable ‘number.

float number = 2.5f;

d)     Display a message ‘happy new year’ using a method from the Systems class.

Click here to read the full post…

admin Education, IDIC, Informatics , , , ,

Bad Behavior has blocked 205 access attempts in the last 7 days.

Bad Behavior has blocked 205 access attempts in the last 7 days.