Promotion
CodeGym University
Learning
Courses
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
Java 25
All quests
All levels
Any status
Questions about tasks
Hot
Mina Nabil
Level 17
Sydney
Question about the task
Currencies
Java Core
,
Level 4
,
Lesson 8
Resolved
A quick question
Hi, is there any difference if I did not put the keyword this in public double getAmount() { return this.amount; }
3/10/21
727
views
10
comments
1
Anthony Chalk
Level 30
London
Question about the task
Archiver (part 10)
Java Multithreading
,
Level 7
,
Lesson 15
Resolved
Please help
I'm particularly confused about points: 1.1) what am I supposed to do with the passed filePath argument? 5.2) what would be the second argument passed to the addNewZipEntry() method in this case? 5.3.2) what fileNames variable?
4/7/21
833
views
13
comments
0
Asia
Level 19
Bydgoszcz
Question about the task
Working with dates
Java Syntax
,
Level 8
,
Lesson 11
Resolved
Help with Java.time
I'm failing the third requirement.
4/7/21
737
views
2
comments
0
Jason
Level 26
Rancho Cucamonga
Question about the task
Inheriting an inner class
Java Multithreading
,
Level 4
,
Lesson 4
Resolved
I don't get it. My ThreeBedroomApt class is all these thing and it's still not passing
the class that is failing is also all the things it is telling me I am failing for. Thanks for your time in advance.
1/29/20
1631
views
6
comments
0
Josephine
Level 1
Normal
Question about the task
Inverted words
Java Multithreading
,
Level 2
,
Lesson 9
Resolved
Why this is not validating?I got the below output in the intellij.Can someone help?
This is my output.... a a rat tar tot tot.. Can someone guide me, what i am doing wrong
4/7/21
686
views
2
comments
0
Ondrej Sulc
Level 8
Prague
Under discussion
Hello, I'd like to ask why my code below was validated as wrong (task 0441). I could not find any drawbacks when testing :( Thanks.
import java.io.*; public class Solution { public static void main(String[] args) throws Exception { BufferedReader bufferedReader = new BufferedReader(new InputStreamReader(System.in)); int a = Integer.parseInt(bufferedReader.readLine()); int b = Integer.parseInt(buff
4/6/21
808
views
2
comments
0
Dmitri
Level 22
Seversk
Question about the task
Iterating through a file tree
Java Collections
,
Level 1
,
Lesson 2
Archived
My code works as described in the task. What is wrong?
I implemented recursive file collection from all inner folders, but my code do not pass. What is wrong?
4/5/21
753
views
9
comments
0
Daniel Whyte
Level 17
Question about the task
OOP: Arrange interfaces
Java Core
,
Level 5
,
Lesson 2
Under discussion
getAllowedAction
Why does getAllowedAction have to return null in order to compile? In theory could it not return something else like a word or sentence and still be OK?
4/6/21
800
views
1
comment
0
Max Sudik
Level 41
Vancouver
Question about the task
Greater than 10? You're not a good fit for us
Java Syntax
,
Level 8
,
Lesson 8
Under discussion
Adding 20 random numbers to set generate different size of sets each time
Can somebody explaim why below code generates sets of different size each time when I populate this set with random numbers? public static HashSet createSet() { // write your code here HashSet numbers = new HashSet<>(); Random randomNumbers = new Random();
4/5/21
825
views
2
comments
0
tony
Level 20
Nis
Question about the task
Exception when working with List collections
Java Syntax
,
Level 9
,
Lesson 6
Resolved
why it's not verified
Can somebody tell me what is wrong here
12/28/18
1548
views
6
comments
0
remote87
Level 18
Sofia
Question about the task
Minesweeper (Part 9/16)
Games
,
Level 0
,
Lesson 0
Under discussion
Something is missing...
I can't pass the last condition, but so far, I think that everything is working as it should. Any ideas?
4/6/21
663
views
2
comments
0
Max Sudik
Level 41
Vancouver
Question about the task
Make a family
Java Syntax
,
Level 8
,
Lesson 11
Under discussion
Explain pls how overloaded constructor works in the provided solution
How does it work? what does this parameter mean Human... children I'm not sure we covered something like that in previous lessons. Will we have explanation of this concept in further lessons? public Human(String name, boolean sex, int age, Human... children) { this.name = n
4/6/21
1102
views
1
comment
0
John
Level 17
Mansfield
Question about the task
Working with dates
Java Syntax
,
Level 8
,
Lesson 11
Under discussion
its printing right condition
anyways I'll try to figure out another way
4/5/21
732
views
4
comments
0
Liliane Top
Level 17
Amsterdam
Question about the task
Task about algorithms
Java Syntax
,
Level 9
,
Lesson 11
Resolved
I need some help
1) why is my code not working to sort the numbers in order from high to low? I did convert the String into an Integer so to be able to sort them as numbers instead of as chars which gave me the wrong results. What part am I missing? 2) It does sort the Strings but I fail to pass the task, why? I ho
4/12/20
1669
views
13
comments
2
Henrique
Level 41
São Paulo
Question about the task
The world doesn't change, we change
Java Multithreading
,
Level 6
,
Lesson 10
Under discussion
What's wrong? (Be sure that the Producer class adds items to the ConcurrentHashMap every half second.)
a
8/6/20
679
views
2
comments
0
Brandon Horvatic
Level 27
Johannesburg
Question about the task
Repeating threads
Java Multithreading
,
Level 3
,
Lesson 8
Under discussion
Passed validation but don't understand why
package com.codegym.task.task23.task2311; /* Repeating threads */ public class Solution { public final String name; public final String food; public final String sound; public Solution(String name, String food, String sound) { this.name = name; this.food = food;
10/29/19
1507
views
8
comments
3
Andrei
Level 41
Question about the task
Refactoring, nested classes
Java Multithreading
,
Level 3
,
Lesson 6
Resolved
Why do I have to declare the constants static also? I don't understand.
Why do I have to declare the constants static also? I don't understand. public class Solution { public final class Constants { public static final String SERVER_IS_CURRENTLY_NOT_ACCESSIBLE = "The server is currently not accessible."; public static final String USER_IS_NOT_AUTH
4/5/21
1008
views
4
comments
0
John
Level 17
Mansfield
Question about the task
Five winners
Java Syntax
,
Level 8
,
Lesson 11
Under discussion
Be sure that the sort method is able to sort arrays of different lengths
hi i think my sort method can but this keep showing this error message
4/5/21
673
views
7
comments
0
John
Level 17
Mansfield
Question about the task
Make a family
Java Syntax
,
Level 8
,
Lesson 11
Under discussion
identifier expected
Identifier expected error when i try to print the objects, anybody know what is wrong?
4/4/21
1738
views
3
comments
0
Luniae
Level 2
Stuttgart
Question about the task
Pets need people
Java Syntax
,
Level 2
,
Lesson 5
Resolved
Question about taks level 2 - Assigning reference variables
Hello everyone , i managed to complete this task for the level 2 : public class Solution { public static void main(String[] args) { //write your code here Cat cat1 = new Cat(); Woman woman1 = new Woman(); cat1.owner = woman1; // i don't get well the meaning
4/4/21
1233
views
3
comments
0
Aryan Babaie
Level 4
Jülich
Question about the task
Minimum of four numbers
Java Syntax
,
Level 2
,
Lesson 8
Resolved
can someone tell me whats wrong with this one ??
public class Solution { public static int min(int a, int b, int c, int d) { int min2; int e = min(a, b); if (e < c && e < b) min2 = e; else if (c < e && c < d) min2 = c; else min2 = d;
3/30/21
946
views
4
comments
0
Lex Icon
Level 17
Sofia
Question about the task
Factory method pattern
Java Core
,
Level 6
,
Lesson 13
Resolved
Got no idea what I've missed, please help.
recommendation from your mentor looked like this: The getImageReader method must return a BmpReader object when ImageTypes.BMP is passed as an argument.
4/3/21
741
views
2
comments
0
Alexandru
Level 22
High Blantyre
Question about the task
Expressing ourselves more concisely
Java Syntax
,
Level 7
,
Lesson 6
Archived
List or Arraylist
List strings = new ArrayList<>(); ---> not accepted; ArrayList = new ArrayList<>(); ----> Accepted; I don't think it's something wrong with the first type of declaration.
4/2/21
522
views
1
comment
0
Sansho
Level 19
Bordeaux
Question about the task
Cat relations
Java Syntax
,
Level 6
,
Lesson 11
Resolved
My output is okay, but my Validation is tellin' me nooOoOoo ♫
Seriously, why is it a no?! Tell me!
4/2/21
697
views
2
comments
0
Anthony Chalk
Level 30
London
Question about the task
Archiver (part 9)
Java Multithreading
,
Level 7
,
Lesson 15
Resolved
Please Help
I'm getting the following mentor recommendations: Point 2: The FileManager constructor must initialize the fileList field to a list of Path objects. Point 4: When the collectFileList(Path path) method receives a regular file, the method must add its path relative to rootPath to the fileList field.
4/2/21
794
views
4
comments
0
Romain
Level 26
Paris
Question about the task
Tetris (part 14)
Java Collections
,
Level 2
,
Lesson 15
Under discussion
Help for the second requirement pls
Thanks
4/2/21
709
views
1
comment
0
Zuz
Level 20
Plovdiv
Question about the task
Take your turn!
Java Core
,
Level 6
,
Lesson 13
Under discussion
My task is not correct but pass. Can someone try to explain me why ?
I pass the task ! But why? I enter the example and the the result is different. How is it correct?They are not sequentially. input: a b c d e f result : a d f b c e public class Solution { public static volatile BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
3/31/21
1133
views
4
comments
0
Ankush Rajput
Level 25
Bhopal
Question about the task
Snake (part 15)
Java Multithreading
,
Level 2
,
Lesson 18
Resolved
Is this bugged ?
Everything is as per requirements still not passing. It keeps saying to call move(0,-1) in case SnakeDirection.UP and other requirements which I am satisfying. Only three requirements pass. I am adding this code in Snake class, as requirement says. public void move(){ if(isAlive()){
4/8/19
1845
views
9
comments
1
Asia
Level 19
Bydgoszcz
Question about the task
Five winners
Java Syntax
,
Level 8
,
Lesson 11
Under discussion
array to arrayList
Hi I was wondering if there is a simple way to convert this array into ArrayList and then just sort it and reverse using collections. Edit: I was able to solve the task by using for loop to pass the values from array to ArrayList and then the other way around. I found some solutions to convert but
3/26/21
684
views
1
comment
0
Andrei
Level 41
Question about the task
Phone number verification
Java Multithreading
,
Level 2
,
Lesson 13
Resolved
2) if the number starts with a digit or opening parenthesis, then it must contain 10 digits. BUT the example they give, is false (0)501234567 - false
2) if the number starts with a digit or opening parenthesis, then it must contain 10 digits This is considered to give a false - (0)501234567 - false What am I missing?
4/2/21
720
views
3
comments
0
Show more
1
...
79
80
81
82
83
...
374
Please enable JavaScript to continue using this application.