Welcome to the Java Programming Forums


The professional, friendly Java community. 21,500 members and growing!


The Java Programming Forums are a community of Java programmers from all around the World. Our members have a wide range of skills and they all have one thing in common: A passion to learn and code Java. We invite beginner Java programmers right through to Java professionals to post here and share your knowledge. Become a part of the community, help others, expand your knowledge of Java and enjoy talking with like minded people. Registration is quick and best of all free. We look forward to meeting you.


>> REGISTER NOW TO START POSTING


Members have full access to the forums. Advertisements are removed for registered users.

Results 1 to 4 of 4

Thread: Help me out with this nested for loop plz..

  1. #1
    Junior Member
    Join Date
    Sep 2012
    Posts
    5
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Help me out with this nested for loop plz..

    IAM CONFUSED WITH j = i part? Some one help me plz...

    class Nested {
    public static void main(String args[]) {
    int i, j;
    for(i=0; i<10; i++) {
    for(j=i; j<10; j++)
    System.out.print(".");
    System.out.println();
    }
    }
    }

    The output produced by this program is shown here:
    ..........
    .........
    ........
    .......
    ......
    .....
    ....
    ...
    ..
    .


  2. #2
    Super Moderator curmudgeon's Avatar
    Join Date
    Aug 2012
    Posts
    1,130
    My Mood
    Cynical
    Thanks
    64
    Thanked 140 Times in 135 Posts

    Default Re: Help me out with this nested for loop plz..

    This is your third copy of the same post! Again, you're succeeding brilliantly.

  3. #3
    Junior Member
    Join Date
    Sep 2012
    Posts
    5
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Re: Help me out with this nested for loop plz..

    Hahaha. Hey listen, can u plz help me, I have wasted alot of tym on this *** for loop!
    Last edited by copeg; September 3rd, 2012 at 10:02 AM. Reason: removed foil language

  4. #4
    Administrator copeg's Avatar
    Join Date
    Oct 2009
    Location
    US
    Posts
    5,320
    Thanks
    181
    Thanked 833 Times in 772 Posts
    Blog Entries
    5

    Default Re: Help me out with this nested for loop plz..

    Thread locked as duplicate
    http://www.javaprogrammingforums.com...sted-loop.html
    samadniz, this is a warning. Foil language and disregard of forum rules - continue on this path and you will be banned.
    Last edited by copeg; September 3rd, 2012 at 10:02 AM.

Similar Threads

  1. Nested For Loop!
    By samadniz in forum Object Oriented Programming
    Replies: 3
    Last Post: September 3rd, 2012, 04:03 PM
  2. Having some nested loop problem
    By joel1314 in forum Loops & Control Statements
    Replies: 13
    Last Post: June 3rd, 2012, 05:04 AM
  3. Nested for loop
    By wolf_fcknHaley33 in forum Loops & Control Statements
    Replies: 2
    Last Post: May 23rd, 2012, 08:49 AM
  4. Nid help in nested loop !!
    By Spice in forum Loops & Control Statements
    Replies: 1
    Last Post: February 14th, 2012, 11:10 AM
  5. nested loop
    By b109 in forum Java Theory & Questions
    Replies: 1
    Last Post: May 30th, 2010, 10:05 AM