public class MyProgram
{
public static void main(String[] args)
{
}
public static void function()
{
int lc = 1;
int mult = 1;
for (int i = 1; i <= 12; i++)
{
System.out.println("Chart of "+i);
lc += 1;
for (int j = 1; j <= 12; j++)
{
System.out.println(lc * mult);
mult += 1;
}
}
}
}
#Hi, how do i fix this?
13 messages · Page 1 of 1 (latest)
⌛ This post has been reserved for your question.
Hey @languid berry! Please use
/closeor theClose Postbutton above when you're finished. Please remember to follow the help guidelines. This post will be automatically closed after 300 minutes of inactivity.
TIP: Narrow down your issue to simple and precise questions to maximize the chance that others will reply in here.
I am trying to make a nested for loop to print the mutliplication tables through 1-12
Hi, how do i fix this?
okay, i found 1 problem: I forgot to put int j = 1;
oh and same for int i = 1; lol
but now my output is a bit weird...
Can't you just multiply i and j?
If you are finished with your post, please close it.
If you are not, please ignore this message.
Note that you will not be able to send further messages here after this post have been closed but you will be able to create new posts.