+ 1
Can anyone please tell me what will be the java code for printing the following pattern?
1 3 5 7 9 1 3 5 7 1 3 5 1 3 1
20 ответов
+ 4
class Pattern
{
public static void main (String[ ] args)
{
for(int i=5;i>=1;i--)
{
int n=1;
for(int j=1;j<=i;j++)
{
System.out.print(n +" ");
n=n+2;
}
System.out.println();
}
}
}
+ 7
I respectfully disagree that is all it is. However, you have not successfully countered my point, so I will leave it there.
+ 5
This is a forum for help, not for doing all of the work for others.
+ 3
Ab SH I care because I really like this app. Part of the point of it is for users to learn.
You didn't help, you DID it entirely.
Imagine trying to learn to talk where another person does all the speaking.
+ 2
Jhazel Rose Hitalia please start your own discussion thread. Include your problem, the task and your code from the code playground. Someone might be able to help you.
+ 1
Why do you care ?
If someone help somebody else .. What is matter?
+ 1
I have another idea
You can learn from your way and from solved scripts..
If you do not see a lot of codes you will not learn, in my opinion.
Let the users take your simple codes that takes 10 min max and enjoy 😇
+ 1
I'm absolutely agree with Ab SH
and i think for better understanding and learning someone need to see code example and discuss it with another member. So... I don't accept arguments above
+ 1
Sergey Samokhvalov Various answers is a good number of comments answering other ones. You can see maybe 4 about the same thing.
Yes, seeing code can be helpful as examples, but finishing the task without giving the OP a try is harmful. Remember the purpose of the app.
I understand this point is already well explained.
0
Ab SH Gojo Saturo Pls avoid giving finished code as answer, because it makes the OP to skip the most important part of learning process. Always prefer giving hints for the OP to find the solution.
0
Emerson Prado , Ausgrindtube okay 🫡
0
Srinivas vedullapalli Pls see my previous answer to Ab SH and Gojo Saturo , and also Ausgrindtube 's. Having the OP finishing the solution helps a lot in learning.
0
You can do it with array like that
https://code.sololearn.com/cgsn7iPqKJrn/?ref=app
0
Sergey Samokhvalov Pls read the various answers about giving finished code
0
Emerson Prado, what is various answers? I see that members of this topic posted code above, why i cant paste my code?
0
now i work as programmer and if i didn't saw code examples and issues with finished code - i had never start my career
- 1
you can see the answer here
https://code.sololearn.com/cV97OZlU0B3L/?ref=app
- 2
Hi
- 2
I want to study coding
How will I start in this sololearn
- 3
Can some know how to Write a program to convert Binary codes to ASCII decimal and to Character equivalent
? In python?
Please help me