Thread: Want help in Structure Array !!

  1. #1
    Registered User
    Join Date
    Dec 2011
    Posts
    3

    Question Want help in Structure Array !!

    Write a programme which will acept
    Code:
    employee_code char [10]
    employee_name char [150]
    employee_basic float
    employee_hra float
    and calculate hra as 10% of basic. The programme should accept 10 records and calculate the hra and show the result in a tabular form.

    Format of table :

    Sl.no. Employee code Employee name BASIC HRA


    Code:
    { use : Structure Array only}

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

    We need to see your work in the program, before we can advise you much. Give it a good start, and if you get stuck on something, then post up what you have, and state the problem. There's really very little that can be posted in response to your request, without just doing the whole thing - which is something we have neither the time nor inclination to do.

    Generally, you want to define the struct itself, above main() in your program, but declare the struct array, inside main(). That way your struct's lay out, is known by all the functions in your program, but the array of actual data, is local, instead of global.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Array with a structure
    By Jenna_Javason in forum C Programming
    Replies: 7
    Last Post: 10-09-2007, 06:58 AM
  2. Dynamic structure with array and array count
    By Nazgulled in forum C Programming
    Replies: 14
    Last Post: 06-08-2007, 10:10 PM
  3. array of structure
    By ashb in forum C++ Programming
    Replies: 11
    Last Post: 03-31-2005, 10:59 AM
  4. structure with array
    By planet_abhi in forum C Programming
    Replies: 5
    Last Post: 12-08-2002, 06:42 PM
  5. structure with 2-dim array
    By sballew in forum C Programming
    Replies: 8
    Last Post: 10-27-2001, 04:30 PM

Tags for this Thread