Help With Dev C++?

Discussion in 'Computer Science & Culture' started by Angelic Being, Oct 13, 2005.

Thread Status:
Not open for further replies.
  1. Angelic Being Registered Senior Member

    Is Anyone Out There Familiar With Dev C++?
  2. Google AdSense Guest Advertisement

    to hide all adverts.
  3. (Q) Encephaloid Martini Valued Senior Member

    I know it inside out and upside down.
  4. Google AdSense Guest Advertisement

    to hide all adverts.
  5. Angelic Being Registered Senior Member


    could you guide me with how to use it? - i am not good at computer programming.
  6. Google AdSense Guest Advertisement

    to hide all adverts.
  7. identityless Registered Senior Member

    What do you want to do?
  8. Angelic Being Registered Senior Member


    am i breaking the forum rules if i say that i need help with an assignment?
  9. Voodoo Child Registered Senior Member

    On the contrary, I think that would be encouraged. The denizens of SciForums would be happy to help you do your homework. Asking them to do your homework would be frowned upon, though.
  10. Angelic Being Registered Senior Member


    "Mathematical Analysis Using C++
    The data file results.dat contains course scores of cs102 students. The course
    scores are stored in ascending alphabetic order by the last name. The format
    of the file is as follows:-
    Student id #, First Name, Last Name, Test 1, Project 1, Test 2, Project 2, Quiz.
    You have been asked to perform some processing on this data and gather
    some statistical measurements. You have to open the file, read in the student
    id#, First Name & Last name into a 2-D array. Have a separate 2-D array to
    read in the all of the scores (test 1, project 1, test 2, project 2 and Quiz.) [The
    first array’s row should match with the second array’s row.]
    • You have to prepare separate analysis reports for each of the
    assessments and save into 6 different output files. Each row in the
    file should be identified & sorted by student id # in ASC order.
    Label the files in accordance to its content, e.g analysisTest1,
    analysisProject1 and etc..
    • Create another file named studentGrade.dat to display the student
    id # with the total marks and corresponding grades. [each
    individual assessment is 20%] Use the table below to find your
    grade.(sort by Grade in ASC order). This file should also contain
    the tally for each grade.
    Mark Grade
    90-100 A+
    78-89 A
    70-77 B+
    60-69 B
    55-60 C+
    48-54 C
    40-47 D
    0-39 E

    • A last file named studentLIST.dat should be created to contain the
    student id#, Last Name & First Name. (sorted by student id# in
    Desc order)
    Analysis Required
    • For each of the separate assessment find the mean, median, and standard
    • For the final grades, find the mean, highest& lowest score, and the variance.
    1. Draw a flowchart to show how the above would be solved
    2. Write C++ program to implement the above flowchart. The program should
    repeat and each time should ask the user for an input filename. It should stop
    when the user presses EXIT when prompted for filename.
    3. You are allowed to use existing functions & codes from the lecture notes, text
    or the labs, but please do acknowledge these functions.
    4. The program should be able to handle any error entry from keyboard!
    5. Finally, draw a graph in MS-Excel showing the grade tally!
    Functions Needed
    • Separate functions to perform the different statistical analysis is required.
    findMean(..), findMedian(…), findSD(…), findVariance(…),
    findHighest(…), findLowest(…)
    • Have a function to read from the files and another to write to the files.
    readDetails(filename, …..)
    writeDetails(filename, …..)

    Student ID# First Name LastName Test 1 Project 1 Test 2 project 2 Quiz
    S123456788 Quiklllu Bheedtr 2 4 5 6 7
    S123456792 Uiiijhk Deeeewrt 12 20 19 11 10
    S123456782 Jashmine Devi 20 19 16 17 16
    S123456789 John Dovi 15 15 15 15 15
    S123456787 Opkiu Ewwq 19 7 16 15 15
    S123456797 Huuuikjy Ghhhngh 11 16 17 18 11
    S123499822 Iuuuyt Hgggghg 10 10 9 8 11
    S123456790 Pnnbgty Hjjjnfh 7 6 4 8 9
    S123456795 Ikkkjhnbg Huyyytu 12 10 10 10 10
    S123456794 Hggyui Jkllllmen 11 10 11 10 11
    S12345322 Bggdedg Jkoooej 12 10 11 8 7
    S123456785 Abhuy Juuyi 6 7 9 0 1
    S123456781 Smith Lal 10 12 8 9 17
    S123456784 Jiit an 5 4 6 7 8
    S123456783 Ratu Singh 18 12 13 14 16
    S123456796 Ufgggty Swwwdft 10 11 1 1 14 16
    S123456791 Iuuuhy Teeeed 8 6 9 8 7
    S12345432 Hggfyio Tlkjkljhlkj 16 5 12 4 11
    S123456786 Iujnht Trredf 12 4 5 7 8
    S123456793 Mnnnhy Wiiiolkj 7 8 9 13 10

    would really appreciate anybodys help - but keep to simple codes if you dont mind.

  11. Facial Valued Senior Member

    Crud. It's been too long since my C programming class. Guess it's time for me to go back to the basics.

    What's probable is that you use an alloc() function to store the memory somewhere.
  12. Angelic Being Registered Senior Member

    yes, i have done that.
  13. identityless Registered Senior Member

    When is it due?
  14. Angelic Being Registered Senior Member

    due on Monday, next week
  15. river-wind Valued Senior Member

    well, teh first thing to do isn't programming. It's figuring out what steps need to occur in order to begin programming.

    so, what's the list of steps that need to occur in order to get to your final goal of "statistical analysis"?
    step 1:eek:pen data file.
    step 2:read data from file

    if you get an idea of the steps, then designing the the code structure will be easier, and you'll be less likely to miss something.
  16. Angelic Being Registered Senior Member


    i have already done that - the problem is that i dont know the codes with which to create the two dimensional array. my compiler keeps on stating errors....
  17. kazakhan Registered Abuser Registered Senior Member

    I think you'd have much more success in getting help if you actually posted at least some of the code you have. If you continue to be vague so will the answers...
  18. Venom (1,000,546 posts)or maybe just Registered Senior Member

    the best i can do to help is give you a simple dynamic allocation for an array of strings, which is a 2d array cause a string is an array of characters

    in c.....

    char *string;
    string = (char *)malloc(sizeof(char) * LENGTHOFSTRING * NUMBEROFSTRINGS);

    and dont forget to delete at the end

    of course LENGTHOFSTRING is how many characters max in a string
    and NUMBEROFSTRINGS is how many strings you want to hold
    i think this is just learning it too, why not give it a try
    im unsure if you need to #include anything special for this

    now c++

    char *string;
    string = new(nothrow) char[sizeof(char) * LENGTHOFSTRING * NUMBEROFSTRING];

    and to delete it is

    delete [] string;
    anyways, give it a shot
    Last edited: Oct 26, 2005
  19. Angelic Being Registered Senior Member

    moderator, you can terminate this thread

Thread Status:
Not open for further replies.

Share This Page