CodeGym
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
  • Jen P
    Level 26
    Question about the task Task No. 1 about integer type conversions
    Java Syntax, Level 10, Lesson 4
    Resolved
    Why there is no "Arithmetic Error" when calculating d = (a + f/c +b) where byte c is actually 0 ?I specifically print out the result : System.out.println("f/c = " + f/c); //f/c = Infinity , where f is double but this will get ArithmeticException : System.out.println("d/c = " + d/c); // ArithmeticException : / by zero , where d is long Why there is a difference? Why both of them throw Arithmet
    • 7/22/19
    • 1281views
    • 1comment
    1
  • Denis
    Level 22
    Kharkiv
    Question about the task Deserialization
    Java Core, Level 10, Lesson 10
    Under discussion
    What is wrong guysNeed help
    • 6/30/19
    • 1440views
    • 1comment
    0
  • Nithin
    Level 35
    Hyderabad
    Question about the task Deserialization
    Java Core, Level 10, Lesson 10
    Resolved
    what is wrong hereplease help
    • 6/4/19
    • 1536views
    • 5comments
    0
  • captain jack
    Level 9
    Mumbai
    Question about the task Duplicating words
    Java Syntax, Level 7, Lesson 9
    Under discussion
    help me pleasewhat should I do to duplicate it
    • 7/13/19
    • 1618views
    • 2comments
    0
  • sowmya
    Level 6
    Chennai
    Question about the task Number of days in the year
    Java Syntax, Level 4, Lesson 4
    Under discussion
    whats wrong with below code?package com.codegym.task.task04.task0414; /* Number of days in the year */ import java.io.*; public class Solution { public static void main(String[] args) throws Exception { InputStream inputStream= System.in; Reader inputStreamReader = new InputStreamReader(inputStream);
    • 10/16/18
    • 2362views
    • 5comments
    0
  • Anita Pal
    Level 14
    Question about the task Escaping characters
    Java Syntax, Level 3, Lesson 6
    Resolved
    Plzz help me,what is wrong in String s2package com.codegym.task.task03.task0316; /* Escaping characters */ public class Solution { public static void main(String[] args) { String s1 = "This is a Windows path: "; String s2 = "C:\\Program Files\\Java\\jdk1.8.0_172\\bin"; String s3 = "This is a Java string: "
    • 7/19/19
    • 1425views
    • 2comments
    0
  • dean
    Level 8
    Deutschland
    Question about the task More Sam-I-Am
    Java Syntax, Level 7, Lesson 9
    Under discussion
    memory heap errorwhy?
    • 5/22/19
    • 1423views
    • 7comments
    0
  • Husain Kothari
    Level 20
    Mumbai
    Question about the task Most frequent bytes
    Java Core, Level 8, Lesson 3
    Resolved
    My program outputs the most frequently used bytes but does not verifyresult = result.substring(0,result.length()-1); is used just to remove the last trailing space.
    • 7/21/19
    • 1680views
    • 2comments
    0
  • Nishant Bhatia
    Level 13
    Navi Mumbai
    Question about the task Snake (Part 17/20)
    Games, Level 0, Lesson 1
    Resolved
    What is the bug?Problems with createNewApple() method.
    • 7/20/19
    • 1239views
    • 3comments
    0
  • fran
    Level 14
    Cordoba
    Question about the task The isomorphs are coming
    Java Core, Level 2, Lesson 12
    Resolved
    I really don't know how to verify the fourth conditionI complete the task but i can't verify the specific condition and get an error when validate the code.
    • 2/13/19
    • 1878views
    • 4comments
    1
  • Yash
    Level 15
    Sugar Hill
    Question about the task What sort of list is that?
    Java Syntax, Level 7, Lesson 6
    Under discussion
    Right output not acceptedMy output is correct but is not accepted.
    • 5/29/19
    • 1775views
    • 3comments
    0
  • Steve
    Level 9
    Denver
    Question about the task R or L
    Java Syntax, Level 7, Lesson 9
    Resolved
    My "love" is not getting printed twice??? else if(x.indexOf('l')!=-1){ list.add(i, x); i++; }
    • 7/20/19
    • 1439views
    • 2comments
    0
  • Jay
    Level 17
    Washington
    Question about the task Move one static modifier
    Java Syntax, Level 7, Lesson 12
    Under discussion
    Help with access modifiers I solved the task relatively easily; however, I feel that my understanding of access modifiers is pretty fuzzy. If anyone can suggest any resources with a clear explanation of this concept, i'd appreciate it.
    • 7/20/19
    • 1528views
    • 2comments
    0
  • Jay
    Level 17
    Washington
    Question about the task R or L
    Java Syntax, Level 7, Lesson 9
    Under discussion
    Struggling with this one When I run my program, it's not duplicating the word "love" even though I added to the list(at least that's what I thought I did). What is the problem? Thanks in advance.
    • 7/19/19
    • 1252views
    • 2comments
    0
  • vish
    Level 3
    Bangalore
    Question about the task Calculate the circumference of a circle
    Java Syntax, Level 2, Lesson 2
    Under discussion
    Can anyone help with code? public class Solution { public static void main(String[] args) { printCircleCircumference(5); } public static void printCircleCircumference(int radius) { radius = 5; double pi = 3.14; double C = 2*pi*radius; System.out.println(C);
    • 7/12/19
    • 2322views
    • 3comments
    0
  • Lei Angelique Hernandez
    Level 2
    Makati
    Question about the task Implement the print method
    Java Syntax, Level 2, Lesson 1
    Under discussion
    How to call in main method twice?How to call in main method twice?
    • 11/13/18
    • 3466views
    • 6comments
    0
  • Tomasz
    Level 13
    Warsaw
    Question about the task Longest string
    Java Syntax, Level 7, Lesson 6
    Archived
    What is wrongCan somebody help me to find what is wrong? Im using "max" to find index of longest string, and "count" to check how many times i should display it (if there is more than 1 longest string). It works fine with: a aa aaa aaaa aaaa
    • 6/5/19
    • 1744views
    • 3comments
    0
  • Baljinder Singh
    Level 20
    Toronto
    Question about the task Cats
    Java Core, Level 4, Lesson 4
    Resolved
    What's the problem here ?
    • 9/21/18
    • 2290views
    • 6comments
    2
  • Igor
    Level 20
    Nis
    Question about the task Software update
    Java Syntax, Level 8, Lesson 11
    Resolved
    It is not workingWhat am I overseeing?
    • 7/19/19
    • 1404views
    • 2comments
    0
  • nagabenang
    Level 6
    Bekasi
    Question about the task Task about algorithms
    Java Syntax, Level 5, Lesson 12
    Archived
    The answer is wrong but why the lesson consider it right? The right answer should be 6, right? But this lesson consider 5 as true anyway. And now the code won't work. I think this solution broke the verification process of this lesson.
    • 7/19/19
    • 1332views
    • 1comment
    0
  • Denis
    Level 22
    Kharkiv
    Question about the task Tracking changes
    Java Core, Level 9, Lesson 11
    Under discussion
    One condition,guysNeed help
    • 6/29/19
    • 1431views
    • 2comments
    0
  • Alex Dumitriu
    Level 17
    Bucharest
    Question about the task Playing Javarella
    Java Syntax, Level 7, Lesson 9
    Under discussion
    Any idea what I'm missing here? Thxpublic class Solution { public static void main(String[] args) throws Exception { //write your code here ArrayList mainList = new ArrayList<>(); ArrayList list2 = new ArrayList<>(); ArrayList list3 = new ArrayList<>(); ArrayList lastList
    • 5/20/19
    • 1467views
    • 5comments
    0
  • hidden #10463947
    Level 7
    Question about the task Adding
    Java Syntax, Level 4, Lesson 16
    Under discussion
    ANSWER package com.codegym.task.task04.task0442; /* Adding */ import java.io.*; import java.util.Scanner; public class Solution { public static void main(String[] args) throws Exception { //write your code here int a = 0; int sum = 0; Scanner scan = new Scanner(Sy
    • 6/14/19
    • 1485views
    • 5comments
    2
  • Neha Anjum
    Level 6
    Hyderabad
    Question about the task Console-based piggy bank
    Java Syntax, Level 5, Lesson 12
    Under discussion
    .....?????public class Solution { public static void main(String[] args) throws Exception { BufferedReader reader = new BufferedReader(new InputStreamReader(System.in)); int sum = 0; boolean isExit = false; while(true) { String s = reader.readLine();
    • 9/21/18
    • 1810views
    • 3comments
    0
  • satya vath
    Level 9
    Mumbai
    Question about the task Remove and insert
    Java Syntax, Level 7, Lesson 6
    Resolved
    Please help me package com.codegym.task.task07.task0711; import java.io.BufferedReader; import java.io.InputStreamReader; import java.util.ArrayList; /* Remove and insert */ public class Solution { public static void main(String[] args) throws Exception { //write your code here ArrayList
    • 11/23/18
    • 2223views
    • 7comments
    0
  • Robert
    Level 3
    Lombard
    Question about the task Rounding numbers
    Java Core, Level 8, Lesson 11
    Resolved
    I can not get this to verifyI have read through all the other questions and can not figure out why this will not pass. In my test file it prints correctly, it has no spaces at the end. I have used Math.round to round my numbers. It still will not pass verification.
    • 7/18/19
    • 1686views
    • 2comments
    0
  • Bazuka
    Level 19
    Krakow
    Question about the task Sum of the digits of a three-digit number
    Java Syntax, Level 3, Lesson 12
    Under discussion
    Hello can u tell me what's wrong?public class Solution { public static void main(String[] args) { System.out.println(sumDigitsInNumber(546)); } public static int sumDigitsInNumber(int number) { int number1 = (5+4+6); return number1; } }
    • 7/17/19
    • 1816views
    • 5comments
    0
  • Michał Kwaśny
    Level 22
    Krakow
    Question about the task Robot wars
    Java Core, Level 3, Lesson 11
    Resolved
    Need help :)I have no idea what is not correct. Can anyone shed some light on it?
    • 7/19/19
    • 1493views
    • 2comments
    0
  • ddi
    Level 18
    Dortmund
    Question about the task The code won't compile…
    Java Syntax, Level 9, Lesson 11
    Resolved
    Can´t find the failure, what am i missing? Can´t find the failure, what am i missing?
    • 7/19/19
    • 1680views
    • 2comments
    0
  • Naveen Dangra
    Level 8
    Rasipuram
    Question about the task In decreasing order
    Java Syntax, Level 7, Lesson 12
    Under discussion
    why it is not verifying the last one?package com.codegym.task.task07.task0728; import java.io.BufferedReader; import java.io.InputStreamReader; /* In decreasing order */ public class Solution { public static void main(String[] args) throws Exception { BufferedReader reader = new BufferedReader(new InputStreamReader(Sys
    • 7/18/19
    • 1457views
    • 2comments
    0
  • 1
  • ...
  • 298
  • 299
  • 300
  • 301
  • 302
  • ...
  • 374
Learn
  • Registration
  • Java Course
  • Help with Tasks
  • Pricing
  • Java Syntax
Community
  • Users
  • Articles
  • Forum
  • Chat
  • Success Stories
  • Activity
  • Affiliate Program
Company
  • About us
  • Contacts
  • Reviews
  • Press Room
  • CodeGym for EDU
  • FAQ
  • Support
CodeGym CodeGym is an online course for learning Java programming from scratch. This course is a perfect way to master Java for beginners. It contains 1200+ tasks with instant verification and an essential scope of Java fundamentals theory. To help you succeed in education, we’ve implemented a set of motivational features: quizzes, coding projects, content about efficient learning, and a Java developer’s career.
Follow us
Interface language
English
Deutsch Español हिन्दी Français Português Polski বাংলা 简体中文 मराठी தமிழ் Italiano Bahasa Indonesia 繁體中文 Nederlands 日本語 한국어 Bulgarian Danish Hungarian Basa Jawa Malay Norwegian Romanian Swedish Telugu Thai Українська Filipino Turkish Azərbaycan Русский Vietnamese
Programmers Are Made, Not Born © 2026 CodeGym
MastercardVisa
Programmers Are Made, Not Born © 2026 CodeGym