Search:

Type: Posts; User: pyler

Search: Search took 0.18 seconds.

  1. Replies
    7
    Views
    1,560

    [SOLVED] Re: Scanner not looping.

    It's to understand what you're trying to do here but your while loop works, once.
    And it will run once as long as value is not equal to 0 in which case you will throw an exception.

    Are you...
  2. Replies
    10
    Views
    939

    Re: Help with paper rock scissors game

    Just a suggestion.
    Make a player class that takes a name and the player's selection.
    Have the player class getName, getResponse ,incrementScore, and getScore methods.
    then include a compare...
  3. Replies
    17
    Views
    3,948

    [SOLVED] Re: Hi Lo Dice Betting

    You are about 70% through. You just need to add a few outputs to your winAmount() method.

    You need to greet the user in main and tell them they have $100.
    Then you get the bet and store it in...
  4. Replies
    1
    Views
    1,441

    Error when loading the SDK

    Eclipse throws this error whenever I start it.
    Error when loading the SDK:
    C:\Users\...\...: Cannot find the declaration of element 'd:layout-devices'.

    ( see attachment for more details )
    ...
  5. Replies
    2
    Views
    1,464

    Re: how to write java data to pdf file

    I did some gagoogling;
    https://community.oracle.com/message/5341572
    Java: convert a file to a byte array, then convert byte array to a file.
  6. [SOLVED] my cirular doubly linked list only adds first number

    I have an add() method for my doubly circular linked list which is supposed to add new Nodes at the end while maintaining the data structure. But when I create a doubly circular linked list and print...
  7. Declaring an object using an interface implemented by its class vs declaring an object using the class

    Suppose you have a generic Dog class of the pet type that implements a DogInterface of the pet type. What is the difference between;

    DogInterface<pet> Rex = new Dog<pet>();
    and
    Dog<pet> Tye =...
  8. Re: How many methods should be included in class definition

    So which is which?
  9. How many methods should be included in class definition

    Suppose you have an abstract class say Sparrow that extends the abstract Bird class. The abstract Bird class has the abstract methods, fly() and run()

    How many methods from the Bird class should...
  10. Best way of implementing a queue's isEmpty() method

    You have a queue called someQ
    There are two ways to find out if the queue is empty()

    head == null;

    size() == 0; or

    size == 0;

    where size() is determined by the number of elements...
  11. Replies
    1
    Views
    1,098

    Updating a specific value in a linked list

    I create and populate someLinkedList with '*' characters as soon as a gameLinkedList object is created, so my class is something like


    private int size;
    public class gameLinkedList{
    private...
  12. Replies
    2
    Views
    1,567

    Re: Populating a LinkedList in java

    Thanks
  13. Replies
    2
    Views
    1,567

    Populating a LinkedList in java

    I have a LinkedList class that implements a game
    I want to create a list and populate it when a LinkedList object is created
    The game constructor takes a word

    My general/basic question is;
    How...
  14. Implementing own generic hash table contains method

    Hi Sorry for the confusion,
    the contains method is inside a class which is basically a hash table that sorts objects of <T,N> types which are in the twos<T,N> interface.


    public class twos<T,N>...
  15. Replies
    1
    Views
    1,109

    implementing generic compareTo()

    I have a generic class that contains a compareTo() method
    I'm getting an error on the method it'self that goes something like;

    Name clash: the method compareTo(T) of type twos<T N> has the same...
  16. Replies
    5
    Views
    1,303

    Re: Method returns empty stack when called

    I want it to return a copy of the this object but with the contents in reverse order. I want to link this to that after all the items from this have been popped, but I can't find the right keyword.
  17. Replies
    5
    Views
    1,303

    Method returns empty stack when called

    I have a stack method that's supposed to return a reversed *copy* of the this object. I need this object to link to that object. Thanks.

    To clarify, the that stack object that's created pushes...
  18. Replies
    3
    Views
    1,173

    My reverse method wont work

    This method is supposed to reverse a stack by making a new stack and pushing popped items from this stack to that and then returning the reverted stack. When I run some tests, it returns an empty...
  19. Replies
    1
    Views
    1,204

    Some of my methods don't run properly

    The reverse stack method in my LinkedStack class is supposed to return a reversed copy of the stack object that uses it. So when I populate somestack with strings as below, and do...
  20. Replies
    2
    Views
    919

    Re: Problem with code

    Thanks for that
  21. Replies
    2
    Views
    919

    Problem with code

    I have a generic LinkedStack with a Node class and a number of methods
    LinkedStack<T>{
    class Node<T>{}//
    void push(T item){}//
    void push(FancyStack<T> s){}//
    T pop(){}
    boolean...
  22. Replies
    2
    Views
    1,608

    Poll: Re: Referencing libraries in java

    Solved the problem.
    I had to create a class in the (default package) that came with the jar file. All's well
  23. Replies
    2
    Views
    1,608

    Poll: Referencing libraries in java

    I have a project folder, under which I have a package named programs.

    Suppose I have a jar file named vivir.jar that contains files that I need to use in some class in my programs package.

    I...
Results 1 to 23 of 23