Redefining arrays

This is a discussion on Redefining arrays within the C Programming forums, part of the General Programming Boards category; this might seem basic but i'm just starting with C (and this forum). I just would like to be clear ...

  1. #1
    Registered User
    Join Date
    Jun 2009
    Posts
    2

    Redefining arrays

    this might seem basic but i'm just starting with C (and this forum).

    I just would like to be clear on the syntax for redefining specific array variables. For example, if i would like example[3][1] to be redefined as 9, what would the syntax be?

  2. #2
    C++ Witch laserlight's Avatar
    Join Date
    Oct 2003
    Location
    Singapore
    Posts
    21,888
    As in assignment to a specific array element? That would be like an assignment to a "ordinary" variable, e.g.,
    Code:
    example[3][1] = 9;
    C + C++ Compiler: MinGW port of GCC
    Version Control System: Bazaar

    Look up a C++ Reference and learn How To Ask Questions The Smart Way

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. pointers & arrays and realloc!
    By zesty in forum C Programming
    Replies: 14
    Last Post: 01-19-2008, 03:24 PM
  2. Replies: 16
    Last Post: 01-01-2008, 03:07 PM
  3. Need Help With 3 Parallel Arrays Selction Sort
    By slickwilly440 in forum C++ Programming
    Replies: 4
    Last Post: 11-19-2005, 09:47 PM
  4. Crazy memory problem with arrays
    By fusikon in forum C++ Programming
    Replies: 9
    Last Post: 01-15-2003, 08:24 PM
  5. sorting arrays
    By Unregistered in forum C++ Programming
    Replies: 3
    Last Post: 10-13-2001, 05:39 PM

Tags for this Thread


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