Thread: i'm getting confused w/ arrays

  1. #1
    Unregistered
    Guest

    i'm getting confused w/ arrays

    ok...all i want to do if for a person to be able to pick a category...by a number...and then enter a number...and then be able to either go to another category...or add what he/she has already entered altogether....doing all of this w/ arrays.....setting them up is pretty easy...but including them in a loop...well, is still easy...but i can't even figure it out enough to get some sample code for you guys...can you help me get started?

  2. #2
    Mayor of Awesometown Govtcheez's Avatar
    Join Date
    Aug 2001
    Location
    MI
    Posts
    8,823
    Here's some pseudocode:

    Code:
    while (input != quit)
      Output menu 
      get user input
      if(userinput == this)
         do this
      else if (userinput == that)
         do that
      ...
    end while
    Kinda get it?

  3. #3
    Unregistered
    Guest
    well, sort of. but not really. sorry, but for some reason it's really confusing me

  4. #4
    Mayor of Awesometown Govtcheez's Avatar
    Join Date
    Aug 2001
    Location
    MI
    Posts
    8,823
    What part is confusing you?

    Look up while loops, if...else structures, and some of the functions in stdio.h, if that helps.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Vertex Arrays
    By Shamino in forum Game Programming
    Replies: 2
    Last Post: 01-08-2006, 01:24 AM
  2. Need Help With 3 Parallel Arrays Selction Sort
    By slickwilly440 in forum C++ Programming
    Replies: 4
    Last Post: 11-19-2005, 10:47 PM
  3. Building B-Tree from Arrays
    By 0rion in forum C Programming
    Replies: 1
    Last Post: 04-09-2005, 02:34 AM
  4. Help with arrays and pointers please...
    By crazyeyesz28 in forum C++ Programming
    Replies: 8
    Last Post: 03-17-2005, 01:48 PM
  5. Merging two arrays.
    By Roaring_Tiger in forum C Programming
    Replies: 2
    Last Post: 08-21-2004, 07:00 AM