Search:

Type: Posts; User: Squiffy

Search: Search took 0.09 seconds.

  1. Replies
    7
    Views
    1,510

    Re: Simple game problem

    Works fine for me. Aren't you missing scissors vs. rock though?

    I think your program would be simpler if you created lowercase versions of the two things to compare and then just compared those...
  2. Replies
    4
    Views
    1,825

    Re: Help, Building List & finding min and max

    Your logic here is a bit tangled.

    For instance, to find the maximum value, you need to do something like this:

    max = 0

    repeat for each list element:

    x = next list element
    if x > max then...
  3. Replies
    3
    Views
    1,455

    Re: Making a living from Java in strange ways :)

    Thanks JavaPF!
  4. Replies
    9
    Views
    6,334

    Re: Using the ArrayList Class

    Hey nice work. But I'd suggest one small change. Your getTransactions() method should simply "return transactions", nothing else.

    In your main, then you can do: ArrayList transactions =...
  5. Replies
    7
    Views
    1,884

    Re: Problem downloading file from internet

    Weird! I ran it with Eclipse "run" and had no problems.

    You could try updating Eclipse. I have JRE7 too. Sounds like an Eclipse problem if it works elsewhere!
  6. Replies
    9
    Views
    6,334

    Re: Using the ArrayList Class

    I think your Account class looks OK. But you need a getTransactions() method that returns the ArrayList of transactions.

    The Transaction class does not need a list of transactions though. In your...
  7. Replies
    1
    Views
    1,772

    Re: Project help, kinda lost

    Just google "java main" -- you'll find an example of a main method straight away!

    For example, if I've got a class called "Car" with a method called start() that I want to test, I could save the...
  8. Replies
    9
    Views
    6,334

    Re: Using the ArrayList Class

    Firstly, you need to make sure that the transaction arraylist in your Account class is set to a new arraylist somewhere. Otherwise you've just got an empty reference that could refer to an array list...
  9. Replies
    7
    Views
    1,884

    Re: Problem downloading file from internet

    Your code works fine for me (see tail end of output below).

    So whatever the problem is, maybe it's not a Java problem. Have you tried other files? Do they all stop or just this one?


    Read =...
  10. Replies
    3
    Views
    1,455

    Making a living from Java in strange ways :)

    Hi there,

    My name's John, I moved to Budapest (Hungary) six months ago and now I'm making a living by teaching stuff on Skype and in person (mainly Java). Plus I'm developing some software to...
Results 1 to 10 of 10