Promotion
CodeGym University
Learning
Course
Tasks
Surveys & Quizzes
Games
Help
Schedule
Community
Users
Forum
Chat
Articles
Success stories
Activity
Reviews
Subscriptions
Light theme
Help with tasks
Reviews
About us
Start
Start learning
Start learning now
All questions
Ask a question
All quests
All levels
Any status
Questions about tasks
Hot
Arjun Kiruthivasan
Level 14
Chennai
Question about the task
A fox is an animal
Java Core
,
Level 3
,
Lesson 4
Under discussion
How to solve this question??
1. Make the Fox class implement the Animal interface. 2. Edit the code so that the getName method is the only method in the Fox class. 3. Don't create additional classes or delete any methods! Requirements: 1. The Fox class must implement the Animal interface. 2. The Fox class must only implement
24.04.2019
1960
views
10
comments
0
Alexandre Desbois
Level 10
Chamarandes-Choignes
Question about the task
R or L
Java Syntax
,
Level 7
,
Lesson 9
Under discussion
NullPointerException
My list is apparently empty, but I don't understand why...
24.12.2021
311
views
1
comment
0
Gellert Varga
Level 23
Szekesfehervar
Resolved
Serializable and the no-args constructor
1.) Why does this program work without the no-args constructor? I read somewhere that if you write readObject and writeObject methods in a descendant class, you need a no-args constructor in the parent class. Elsewhere I read that if you want to serialize a (serializable) class whose parent is not s
21.12.2021
1069
views
4
comments
0
MaGaby2280
Level 41
Guatemala City
Question about the task
How to avoid Copy+Paste
Java Multithreading
,
Level 4
,
Lesson 6
Resolved
Advise on the fifth condition!
If someone could give me some advise... I cannot pass the fifth condition. I have trying for days and cannot find the bug. Thank you!
04.08.2020
424
views
3
comments
1
Alexandre Desbois
Level 10
Chamarandes-Choignes
Question about the task
R or L
Java Syntax
,
Level 7
,
Lesson 9
Under discussion
Error with compilation that I don't get
I don't get what intelliJ is telling me : Exception in thread "main" java.util.ConcurrentModificationException at java.util.ArrayList$Itr.checkForComodification(ArrayList.java:911) at java.util.ArrayList$Itr.next(ArrayList.java:861) at com.codegym.task.task07.task0716.Solution.fix(Solution.java
23.12.2021
594
views
1
comment
0
Alexandre Desbois
Level 10
Chamarandes-Choignes
Question about the task
Words in reverse
Java Syntax
,
Level 7
,
Lesson 9
Under discussion
Why my code doesn't compile ?
I guess I am wrong with this part: System.out.println(list.get(list.size() - i)); The whole code: public class Solution { public static void main(String[] args) throws Exception { BufferedReader reader = new BufferedReader(new InputStreamReader(System.in)); ArrayList list =
23.12.2021
194
views
1
comment
0
Alexandre Desbois
Level 10
Chamarandes-Choignes
Question about the task
Ascending numbers
Java Syntax
,
Level 6
,
Lesson 11
Under discussion
Why not j = i + 1 ?
Why is it int j = i and not int j = i + 1 like that : for (int j = i + 1; j < array.length; j++) I ran the program with int j = i + 1, and it works, but I don't understand why it also works with int j = i (because we would compare the same element in the array? array[0] with array[0] instead
22.12.2021
372
views
4
comments
0
Filip
Level 4
Karlovac
Question about the task
Display right away
Java Syntax
,
Level 3
,
Lesson 3
Resolved
add public static void printString(String s) method
Hi, i need help with "Hello, Amigo!"??
13.11.2018
4624
views
7
comments
0
Justin Smith
Level 41
Greenfield, USA
Question about the task
Snake (part 11)
Java Multithreading
,
Level 2
,
Lesson 18
Under discussion
CreateMouse method not validating
This seems like very basic stuff, but I can't figure out why it won't accept my code.
21.12.2021
332
views
5
comments
0
Tian Pro
Level 23
Cape Town
Question about the task
Find the bugs
Java Core
,
Level 10
,
Lesson 10
Resolved
But it's working!? Why the last condition STILL not verified?
I'm pretty darn frustrated with this one to be quite honest >.< Ended up taking the advice from the other help answers but for some reason it still doesn't verify. Anyone know what's missing? :'D
27.02.2020
1448
views
13
comments
1
public enum WaysToDie
Level 23
Denver
Question about the task
Greater than 10? You're not a good fit for us
Java Syntax
,
Level 14
,
Lesson 7
Resolved
Por que esta?
So my code seems to fulfill all the requirements yet it is still failing.
21.12.2021
477
views
3
comments
0
Grzegorz
Level 9
Question about the task
2048 (Part 4/18)
Games
,
Level 0
,
Lesson 2
Under discussion
how can I run the code before verifytask in IDEA
s
21.12.2021
493
views
9
comments
0
Luniae
Level 2
Stuttgart
Question about the task
Our first converter!
Java Syntax
,
Level 2
,
Lesson 2
Resolved
Question about the converter task
Hello everyone, i have a question about the converter task. I'd like to know if casting the double type like this is another possible way like writing 9/5.0 public static double convertCelsiusToFahrenheit(int celsius) { //write your code here double TF = (double)9/5 * celsius + 3
02.04.2021
619
views
2
comments
1
Johannes
Level 27
Centurion, Pretoria
Question about the task
Minimum changes
Java Core
,
Level 10
,
Lesson 10
Under discussion
Can someone please explain to me why the constructor of the B and C class is calling Super(name) ?
I am confused again. I am not modifying the parent class if I instantiate a new B or C class ? C c = new C ("Peter"); (Why would I want to pass that name to the Parent or Base (super) class ? What on earth is achieved by doing that ?) Thanks for your attention ;)
22.04.2020
525
views
1
comment
0
Alexis M
Level 18
France
Question about the task
Minesweeper (Part 6/16)
Games
,
Level 0
,
Lesson 0
Under discussion
countMineNeighbors () est un problème
Bien le bonjour! Quelqu'un peut m'éclairer sur mon erreur ? Je n'arrive pas a faire rouler la méthode countMineNeighbors (). Ca compile bien mais la task ne veut pas se valider... Merci d'avance :)
18.12.2021
340
views
1
comment
0
public enum WaysToDie
Level 23
Denver
Question about the task
Minimum of three numbers
Java Syntax
,
Level 7
,
Lesson 4
Resolved
Same problem different problem.
Again my code is producing the expected output but it continues to fail. Where have I gone wrong?
18.12.2021
252
views
2
comments
0
Angel Stefan
Level 23
Sibiu
Question about the task
Number of letters
Java Syntax
,
Level 10
,
Lesson 11
Resolved
but still... :D
I realy don t know what to do anymore! This code do the job but still... :D Any hints? Tk you!
09.12.2021
441
views
20
comments
0
Grzegorz
Level 9
Question about the task
Snake (Part 7/20)
Games
,
Level 0
,
Lesson 1
Under discussion
need help
three task are not passed
15.12.2021
379
views
1
comment
0
Anonymous #10843241
Level 14
Bentonville
Under discussion
level 11 lesson 6 first task - Pls help me understand why type casting needed
In below example why should I type cast " CellPhone cellPhone = (CellPhone) o;" instead of directly accessing "Objects.equals(vendor, o.vendor) && Objects.equals(model, o.model);" ?. When I use "o." it gives oblect not found though its passed as part of parameter.
13.12.2021
388
views
3
comments
0
0wis
Level 6
Paris
Question about the task
Boss, something weird is happening
Java Syntax
,
Level 5
,
Lesson 12
Under discussion
Why I don't fill the requirements ? Using the "sz" parameter of "InputStreamReader"
-It does read the numbers from the keyboard -There is only one main method (this one is valid) -The program displays a string that starts with "Sum =" -And it ends with the sum of the entered numbers. Maybe I have done something wrong but I struggle to find what, my code seems to be valid.
13.12.2021
400
views
7
comments
0
Romain
Level 26
Paris
Question about the task
Make a word chain
Java Multithreading
,
Level 2
,
Lesson 9
Under discussion
'if possible' in 7th requirement
What does mean "if possible" in the 7th requirement ? Should we delete all word without any correspondence with the first or last letter of the others words ?
25.03.2021
567
views
7
comments
0
Justin Smith
Level 41
Greenfield, USA
Question about the task
Find a substring
Java Multithreading
,
Level 2
,
Lesson 5
Under discussion
can't get last condition
I've tested with numerous strings of different lengths and different numbers of spaces, empty string, null. All of them either produce a substring that matches the requirement (with no leading or trailing spaces), or throws the required exception. There is one situation where the conditions aren't
12.12.2021
445
views
3
comments
0
Szymon
Level 41
Warsaw
Question about the task
Log parser (part 1)
Java Collections
,
Level 7
,
Lesson 15
New
I need help guys
.
13.12.2021
347
views
0
comments
0
Gellert Varga
Level 23
Szekesfehervar
Resolved
Serialisation in a custom code example -- NotActiveException
I wanted to try and test a lot of things about serialization/deserialization with a made-up code, just for myself. Unfortunately, I got stuck at the very beginning. Here is the code: import java.io.*; public class Solution implements Serializable { // private int age; private int wei
09.12.2021
449
views
10
comments
0
Hoist
Level 32
San Diego
Question about the task
Favorite dish
Java Syntax
,
Level 7
,
Lesson 2
Under discussion
See commented out code I have been using to get the right output. No success. Ideas ??
Hmmmm ... don't change what's in the main method variables / parameters .... Ideas ? I have been changing out the commented code. It bombs ....
08.12.2021
302
views
3
comments
0
RMR
Level 20
Birmingham
Question about the task
Writing to a file from the console
Java Core
,
Level 3
,
Lesson 11
Under discussion
Not passing verification
I am unsure why I am not passing the verification, because when I write: B:\Documentos\temp.txt Line1 Line2 Line3 exit I end up having the file as requested, I also tried changing line 32 by content = content + newline; with identical results.
10.12.2021
331
views
1
comment
0
Angel Stefan
Level 23
Sibiu
Question about the task
Functionality is not enough!
Java Syntax
,
Level 10
,
Lesson 11
Resolved
The number is not lost
Error: "If an empty string is entered after a number, then that number should also be displayed (it must not be lost)." HashMap can work with null key, no?
09.12.2021
616
views
1
comment
0
Anonymous #10864887
Level 22
Question about the task
Correct order
Java Syntax
,
Level 7
,
Lesson 2
Under discussion
Can anyone explain me please the solution of the reverseArray() method?
Can anyone explain me please the solution of the reverseArray() method? I didn't get it :(
22.11.2021
706
views
8
comments
1
Gellert Varga
Level 23
Szekesfehervar
Question about the task
Overriding serialization
Java Core
,
Level 10
,
Lesson 7
Resolved
Overriding serialization -- and the defaultReadObject() method
The readObject() method of ObjectInputStream has a type: it returns Object. Therefore, I find it easy to understand the following example code used in the deserialization: Cat newCat = (Cat) objectinputstream.readObject(); However, in the task-2015, we used the objectinputstream.defaultReadObjec
07.12.2021
489
views
2
comments
0
M suleman
Level 20
Lahore
Question about the task
DownloadException
Java Core
,
Level 8
,
Lesson 5
Under discussion
not running
*/ import java.io.*; import java.util.*; public class Solution { public static void main(String[] args) throws DownloadException { try{ BufferedReader r = new BufferedReader(new InputStreamReader(System.in)); String file1= r.readLine(); FileInputStream f = new FileInputStream(fil
04.11.2018
1380
views
2
comments
0
Show more
1
...
45
46
47
48
49
...
366
Please enable JavaScript to continue using this application.