Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 6 of 6
  1. #1
    New Coder
    Join Date
    Aug 2008
    Location
    India
    Posts
    88
    Thanks
    3
    Thanked 0 Times in 0 Posts

    PHP script to generate sequence

    Can anyone help me with a script that generates the foll:
    Code:
         1
       1 2  3
    1  2 3  4  5
       1 2  3
         1
    In love with PHP,Mysql & Javascript

  • #2
    New Coder
    Join Date
    Jan 2010
    Location
    UT
    Posts
    35
    Thanks
    1
    Thanked 3 Times in 3 Posts
    haha, looks like a classic for loop homework assignment if you ask me not sure if I should help lol
    Just here to help.

  • #3
    New Coder
    Join Date
    Aug 2008
    Location
    India
    Posts
    88
    Thanks
    3
    Thanked 0 Times in 0 Posts
    Quote Originally Posted by Zoic View Post
    haha, looks like a classic for loop homework assignment if you ask me not sure if I should help lol
    Ya,it was asked in an written test..
    In love with PHP,Mysql & Javascript

  • #4
    Senior Coder tomws's Avatar
    Join Date
    Nov 2007
    Location
    Arkansas
    Posts
    2,644
    Thanks
    29
    Thanked 330 Times in 326 Posts
    From the posting rules:
    1.5) No homework assignments - Do not post your entire homework assignment and request that other members do it for you. This is considered cheating, and your thread may even be used by your school to prove your guilt. Now, you may ask for advice or help on a specific aspect of your assignment that you're having trouble with. Use common sense as far as what's acceptable in terms of soliciting help with homework assignments.
    Are you a Help Vampire?

  • #5
    New Coder
    Join Date
    Aug 2008
    Location
    India
    Posts
    88
    Thanks
    3
    Thanked 0 Times in 0 Posts
    Iam not really asking for readymade code..
    All i want is the logic to proceed on it...
    In love with PHP,Mysql & Javascript

  • #6
    Senior Coder tomws's Avatar
    Join Date
    Nov 2007
    Location
    Arkansas
    Posts
    2,644
    Thanks
    29
    Thanked 330 Times in 326 Posts
    Here's the pseudocode:
    Code:
    print {this line of numbers and spaces}
    print {this line of numbers and spaces}
    print {this line of numbers and spaces}
    print {this line of numbers and spaces}
    print {this line of numbers and spaces}
    Are you a Help Vampire?


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •