Promotion
CodeGym University
Java FullStack
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
Srividya
Level 3
Bangalore
Question about the task
Square of a number
Java Syntax
,
Level 1
,
Lesson 8
Archived
Write a program that displays the square of 5 on the screen.
Hi, Below is the code I could write for the task (task01.task0127-Square of a number). I have two errors displayed, 1> The main method should display the result of the sqr method. 2> The displayed text must match the task conditions. So, kindly help me with the solution. Thank You.
9/25/18
2702
views
3
comments
0
PRADYUMNA HEGDE
Level 2
SHIVAMOGGA
Question about the task
Display the square of a number
Java Syntax
,
Level 1
,
Lesson 3
Under discussion
I cant able to identify the mistakes. Please help me
public class Solution { public static int number = 5; public static void main(String[] args) { //write your code here int number = 5; number = (number * number); System.out.print(number); } }
10/5/18
1618
views
1
comment
0
WatWat
Level 9
Vancouver
Question about the task
Minimum of four numbers
Java Syntax
,
Level 2
,
Lesson 8
Under discussion
Finished task - but need clarification on something.
There are 2 methods called min - so how does main know which one to use for the final output? Is it the order they are written? Its confusing that there can be 2 methods of the same name.
10/2/18
1685
views
3
comments
0
Shahanshah Alam
Level 9
Mohali
Question about the task
Cat relations
Java Syntax
,
Level 6
,
Lesson 11
Under discussion
help please...what cause wrong output
wrong output
9/26/18
2390
views
19
comments
0
Srividya
Level 3
Bangalore
Question about the task
Minimum of three numbers
Java Syntax
,
Level 2
,
Lesson 8
Resolved
Minimum of three numbers
Please help with resolving the ... "The min method must return the minimum of the numbers a, b, and c." error. Thank You.
10/3/18
2911
views
2
comments
0
Manjunath Deva
Level 5
Bangalore
Under discussion
i'm not getting this please help me to overcome.
package com.codegym.task.task05.task0521; /* Calling a constructor from a constructor */ public class Circle { public double x; public double y; public double radius; public Circle(double x, double y, double radius) { this.x = x; this.y = y; this.radius
10/4/18
1506
views
2
comments
0
Yusra Ansari
Level 9
Karachi
Question about the task
Choose healthy food! Choose fruit!
Java Syntax
,
Level 1
,
Lesson 8
Archived
Throwing error Unable to resolve
Unable to resolve my last error
9/10/18
1646
views
5
comments
0
chandana
Level 1
Southfield
Question about the task
I think being a programmer is cool
Java Syntax
,
Level 0
,
Lesson 3
Under discussion
No result
i did not get the result for my first task, its showing some error, please help me understand my mistake
10/3/18
1650
views
4
comments
0
Nehal Abubakar
Level 7
Karachi
Question about the task
Lonely arrays interact
Java Syntax
,
Level 7
,
Lesson 4
Archived
it's giving an error in x.length. Help me out plzzzzz
package com.codegym.task.task07.task0703; import java.io.BufferedReader; import java.io.InputStreamReader; import java.util.Scanner; import java.lang.String; /* Lonely arrays interact */ public class Solution { public static void main(String[] args) throws Exception { //write your c
10/3/18
1783
views
3
comments
0
WonderWoman
Level 8
Bangalore
Question about the task
Crossing the road blindly
Java Syntax
,
Level 4
,
Lesson 4
Resolved
What is wrong with the code?
What is wrong with the code? Is Java 8 code acceptable here?
9/10/18
2344
views
7
comments
0
MARIO
Level 4
Rosario
Under discussion
I think something is wrong
John Squirrels told me that I have to leave my question here, so I'm doing that: Hi. I think something is wrong in https://codegym.cc/quests/lectures/questsyntax.level04.lecture04 because I've tried a lot of possibilities and never failed. But when I want to verify, an apparent error happen. Th
10/2/18
1777
views
2
comments
0
manoj deo
Level 3
Jakarta
Question about the task
Predictions
Java Syntax
,
Level 3
,
Lesson 8
Under discussion
??
why??
10/1/18
1758
views
2
comments
0
iqbalhussain
Level 2
Peshawar
Question about the task
Let's count
Java Core
,
Level 7
,
Lesson 10
Under discussion
Please Help
I did'nt understand which method should use in Solution class for waiting until the thread ends. Should I use join() method or any other method?
10/3/18
1842
views
1
comment
0
Samir
Level 4
Mumbai
Question about the task
Plan to conquer the world
Java Syntax
,
Level 3
,
Lesson 8
Resolved
Unable to identify the mistake , please help .
package com.codegym.task.task03.task0318; /* Plan to conquer the world */ import java.io.BufferedReader; import java.io.InputStreamReader; public class Solution { public static void main(String[] args) throws Exception { //write your code here BufferedReader reader = new Bu
9/10/18
2112
views
3
comments
0
Ankush Rajput
Level 25
Bhopal
Question about the task
Counting commas
Java Core
,
Level 8
,
Lesson 5
Resolved
help
Closing all streams still it is showing "The stream used to read the file must be closed".
9/17/18
2025
views
4
comments
0
Sindhura
Level 15
Delhi
Question about the task
Display numbers in reverse order
Java Syntax
,
Level 7
,
Lesson 12
Under discussion
whats wrong with this?
package com.codegym.task.task07.task0719; import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.util.ArrayList; /* Display numbers in reverse order Enter 10 numbers from the keyboard and put them in a list. Display them in reverse order. Each ele
10/3/18
1866
views
2
comments
0
Srividya
Level 3
Bangalore
Question about the task
Pay raise
Java Syntax
,
Level 2
,
Lesson 2
Resolved
Pay Raise
Hi, I tried, 1> a=(a+1000); System.out.println("Your salary is: (a) dollars per month."); 2> System.out.println("Your salary is: (a+1000) dollars per month."); 3> a=(a+1000); System.out.println("Your salary is:" +a+ "dollars per month."); it is incorrect, so how shou
9/28/18
3085
views
4
comments
0
Mihai Hurezanu
Level 2
Venlo
Under discussion
Level 2 lesson 1
Ok, so I get that: public static void print(String s) defines public class Solution { public static void main(String[] args) { print("Java is easy to learn!"); print("Java opens many opportunities!"); } as String s. My question is, how could I without having learned how
10/2/18
1551
views
1
comment
0
Sam
Level 2
Delhi
Question about the task
Crazy eights
Java Syntax
,
Level 2
,
Lesson 5
Resolved
This is frustrating ..how do i get over it?
Still says; You initialized too few variables. What's the problem in this code? i need a hint!
8/20/18
2415
views
4
comments
0
Joyonta Saha
Level 31
Question about the task
Player and Dancer
Java Core
,
Level 4
,
Lesson 4
Resolved
haveFun method giving correct output however not passing validation
need help!
9/22/18
2641
views
10
comments
0
Durga Prasad
Level 3
Chennai
Under discussion
reference variables
I understand the first sentence. but how the second statment "classes can be created inside other class" are releated
8/13/18
1609
views
1
comment
0
Pawan Harde
Level 4
Mumbai
Question about the task
Cats in the Universe
Java Syntax
,
Level 4
,
Lesson 2
Under discussion
this one
i hope its attached it
10/2/18
1626
views
1
comment
0
Sindhura
Level 15
Delhi
Question about the task
Remove and insert
Java Syntax
,
Level 7
,
Lesson 6
Resolved
couldnot get what is the error
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
10/2/18
1879
views
2
comments
0
Arko Sarkar
Level 8
Mumbai
Question about the task
Family relations
Java Syntax
,
Level 2
,
Lesson 2
Under discussion
man.wife and Woman wife in class Man?
man.wife means what? If it was Man.wife then it'd have been class Man and variable wife, where this variable wife is of class Woman(as given in predefined code). What does this all mean? Also if the class is static then doesn't that mean that we should access it using class_name.(method_name/var_na
8/23/18
1800
views
2
comments
0
Shahanshah Alam
Level 9
Mohali
Question about the task
Shuffled just in time
Java Syntax
,
Level 7
,
Lesson 12
Under discussion
help please
its showing output [ c, d, e, a, c] for 5 2 a b c d e
9/30/18
1635
views
2
comments
0
Azhar Iqbal
Level 18
Multan
Question about the task
Even and odd digits
Java Syntax
,
Level 6
,
Lesson 5
Resolved
where is problem ???
A little hint is appreciated
9/30/18
2034
views
2
comments
0
Vishal Patil
Level 5
Question about the task
Parenthetical brainteaser
Java Syntax
,
Level 3
,
Lesson 4
Resolved
Getting the number 537
I tried many possibilities here. I got numbers close to 537 like 535, 534 but not 537. Been on this problem for two days now. Just how do we get 537 ?
7/30/18
2587
views
9
comments
0
kirti
Level 8
Question about the task
Seasons on Terra
Java Syntax
,
Level 4
,
Lesson 4
Resolved
helpp
what is the problem in my code?
9/9/18
2236
views
3
comments
0
code_k
Level 16
chennai
Question about the task
Creating cats
Java Syntax
,
Level 5
,
Lesson 9
Resolved
doubt
any thing is wrog in the code
9/29/18
2138
views
1
comment
0
tony
Level 20
Nis
Question about the task
Square of a number
Java Syntax
,
Level 1
,
Lesson 8
Archived
Check this code
What is wrong with this code I got 25 as a result
9/28/18
1732
views
5
comments
0
Show more
1
...
366
367
368
369
370
...
375
Please enable JavaScript to continue using this application.