Write programs to print the following shapes using loops?

This is a discussion on Write programs to print the following shapes using loops? within the C Programming forums, part of the General Programming Boards category; 1- ***** **** *** ** * 2- ***** **** *** ** * 3- * ** *** **** ***** 4- * ...

  1. #1
    Registered User
    Join Date
    Oct 2012
    Posts
    1

    Write programs to print the following shapes using loops?

    1-
    *****
    ****
    ***
    **
    *

    2-
    *****
    ****
    ***
    **
    *
    3-
    *
    **
    ***
    ****
    *****

    4-
    *
    ***
    *****
    *******
    *********

  2. #2
    and the hat of wrongness Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    32,673
    Announcements - C Programming
    Now post your attempt.

    Don't just dump your assignment and sit back, expecting finished code you can run to teacher with.
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.
    I support http://www.ukip.org/ as the first necessary step to a free Europe.

  3. #3
    Registered User
    Join Date
    Sep 2006
    Posts
    8,868
    Welcome to the forum Jamal!

    Look at those shapes! Do you see the patterns, inside those shapes? Find them, and with loops, you can easily draw your shapes.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Replies: 15
    Last Post: 06-13-2012, 12:34 PM
  2. Replies: 2
    Last Post: 08-17-2011, 08:07 AM
  3. how to write programs in pelles c??
    By Abhas in forum C Programming
    Replies: 13
    Last Post: 04-11-2011, 12:32 AM
  4. How to draw shapes with only for loops?
    By CplusplusNewb in forum C++ Programming
    Replies: 16
    Last Post: 10-17-2009, 04:09 PM
  5. Reroute where programs write to
    By willc0de4food in forum C Programming
    Replies: 7
    Last Post: 09-21-2005, 04:48 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21