I'm working on a Web Server project and I'm trying to pass a test. It keeps failing so far.
Test
package tests.webserver667.responses.writers;
import static...
Type: Posts; User: siid14
I'm working on a Web Server project and I'm trying to pass a test. It keeps failing so far.
Test
package tests.webserver667.responses.writers;
import static...
Indeed. It worked. I put Scanner object out of the loop and put a input.close; instead of using try resource.
--- Update ---
so @Norm -- what is the issue when "a new Scanner object is created...
I have this output :
[1, 2, 3, 4, 5, 6, 7, 8]
Enter a number : 4
3
Enter a number : Exception in thread "main" java.util.NoSuchElementException
at...
I'm working on a problem where I have to set up a dictionary with keys and values. I implemented Google Guava to use multimap.
My issue is that I do not know how to set up two different values for...
From the original post, I only corrected the driver about the "cannot resolve error" that does not appear anymore now. So it is fixed.
import java.util.Scanner;
//
// - Do not change the...
I fixed the cannot resolve the error, thanks for the help on that point.
I fixed it by writing : "StackInterface<Character> myStack = new OurStack<>();"
With OurStack the class that implements...
I have this code where I'm trying to implement the isPalindrome method using Stack but I get a "cannot be resolved to a type". What to understand from that and how to fix it?
Here is my output
...
Can you give me a line code example ? with the 'this'?
So you mean that I can call csc220Bag within my removeAllOccurence knowing that this is declared in the driver class?
Cause if I try to call it into the removeAllOccurence, I get an cannot...
Actually, when I review the code, you are right. aBag is an argument to a method.
In fact, I think the content that I'm trying to work on comes from the csc220Bag that you can see into the void...
"public class LinkedBagCSC220JavaDriver" is the aBag object
"public final class LinkedBag<T> implements PrimaryDataStructureBagInterface<T> {" is the removeAllOccurence class
you can see...
within "private static void testAdd(PrimaryDataStructureBagInterface<String> aBag) {". The content of aBag in there is what I'm looking to work on in my removeAllOccurence method.
If I pass this...
but it means modify my driver right? (notice that I cannot modify it as I stated)
I'm working on implementing a code where the output I'm looking for is the following
=== LINKED BAG 220 JAVA ==========================================================
[+] Creating a CSC220...
I figure it out, using a package extension in VSC
Okay, I see. Also. quick question, were you able to compile the code. Cause as. it is when I try it says :
LinkedBagCSC220JavaDriver.java:32: error: cannot find symbol
private static void...
I wanna know if I'm right with my understanding of my first concern
Just added the interface class
I'm trying to understand the behavior of on how the elements of a String[] contentsOfBag are added into a linkedbag which is csc220bag (for this programming case).
First concern: from my...
Y. DANIEL LIANG
I have two statements that I would like examples/deep explanations on.
Here there are :
(1)
"Always reference static variables and methods from a class name (rather
then a reference...
Can someone explain that error? I do not get what they mean by saying "Index -1", I don't have such an index in my code ??
Exception in thread "main" java.lang.ArrayIndexOutOfBoundsException:...
@AngleWyrm, where could i get more ressource about the format of the code you use on the last line to learn?
Seems very useful
Are you telling me that I perfectly converted my array into a linkedList but your point is that it is an LinkedList of an Array of Int right.
Is that what you telling me?
I'm looking at how to convert an array of int numbers to a Linked list?
Here is my take but it doesn't work
int[] numbers = { 1, 4, 17, 7, 25, 3, 100 };
Arrays.sort(numbers);
...