Thread: newbie needs help

  1. #1
    Registered User
    Join Date
    Sep 2007
    Posts
    16

    parallelogram for statement

    Ok so here the problem i just got into a beginning programming C class and my teacher kind of sucks and i would love some help....

    basically im writing a program that writes a parallelogram with a input of a width and a length...

    so basically if you what the length to be 5 and you want the width to be 4 the output would look like this

    *****
    *****
    *****
    *****
    (each row moves over to the right about 2 spaces everytime it goes to the next line)

    pretty simple im assuming... i pretty much understand everything on how to do everything but the for statement part or the while statement im currently trying to use the for statement because i think it is easiest to read... but for the life of me i cant get it to compile and after i input my 2 numbers print anything near to the right thing... if anyone could help me with the basic set up and a brief explanations i would absolutely love it... thanks so much

    surfingbum18
    Last edited by surfingbum18; 09-25-2007 at 12:29 AM.

  2. #2
    and the hat of int overfl Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    39,659
    Answered already http://cboard.cprogramming.com/showthread.php?t=93931
    Please don't post the same thing multiple times.
    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.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. getting to grips with allegro and ms vc++ (newbie)
    By jimjamjahaa in forum C++ Programming
    Replies: 4
    Last Post: 11-18-2005, 07:49 PM
  2. Newbie in problem with looping
    By nrain in forum C Programming
    Replies: 6
    Last Post: 11-05-2005, 12:53 PM
  3. Newbie Programmer
    By Extropian in forum C++ Programming
    Replies: 3
    Last Post: 05-18-2004, 01:17 PM
  4. C++ newbie / linux not so newbie question
    By goldmonkey in forum C++ Programming
    Replies: 7
    Last Post: 12-13-2003, 12:27 PM
  5. Newbie Game Develpoers Unite!
    By Telenosis in forum Game Programming
    Replies: 10
    Last Post: 06-22-2002, 02:02 PM