Need Program - Programmers Heaven

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

Need Program

triky3000triky3000 Posts: 8Member
I need a program wich contained arrays and a little database made with record. for example make a program wich showed the marks of 5 students. Could someone help ? PLEASE...

Comments

  • zibadianzibadian Posts: 6,349Member
    : I need a program wich contained arrays and a little database made with record. for example make a program wich showed the marks of 5 students. Could someone help ? PLEASE...
    :
    Start by defining your records. Then define your array. Finally write a procedure to fill one record, show one record, show all records, etc.
    [code]
    type
    TStudent = record
    Name: string;
    Mark: integer;
    end;

    const
    MaxStudents = 20;

    type
    TStudents = array[0..MaxStudents-1] of TStudent;

    var
    Students: TStudents;

    procedure EditStudent(index: integer);
    begin
    { Write code to update indexth student }
    end;

    procedure ShowStudent(index: integer);
    begin
    { Write code to show indexth student's info }
    end;

    procedure ShowAllStudents;
    var
    i: integer;
    begin
    for i := 0 to MaxStudents-1 do
    ShowStudent(i);
    end;
    [/code]
  • triky3000triky3000 Posts: 8Member
    : : I need a program wich contained arrays and a little database made with record. for example make a program wich showed the marks of 5 students. Could someone help ? PLEASE...
    : :
    : Start by defining your records. Then define your array. Finally write a procedure to fill one record, show one record, show all records, etc.
    : [code]
    : type
    : TStudent = record
    : Name: string;
    : Mark: integer;
    : end;
    :
    : const
    : MaxStudents = 20;
    :
    : type
    : TStudents = array[0..MaxStudents-1] of TStudent;
    :
    : var
    : Students: TStudents;
    :
    : procedure EditStudent(index: integer);
    : begin
    : { Write code to update indexth student }
    : end;
    :
    : procedure ShowStudent(index: integer);
    : begin
    : { Write code to show indexth student's info }
    : end;
    :
    : procedure ShowAllStudents;
    : var
    : i: integer;
    : begin
    : for i := 0 to MaxStudents-1 do
    : ShowStudent(i);
    : end;
    : [/code]
    :
    dam didn't got the idea of this prog... :/
  • zibadianzibadian Posts: 6,349Member
    : : : I need a program wich contained arrays and a little database made with record. for example make a program wich showed the marks of 5 students. Could someone help ? PLEASE...
    : : :
    : : Start by defining your records. Then define your array. Finally write a procedure to fill one record, show one record, show all records, etc.
    : : [code]
    : : type
    : : TStudent = record
    : : Name: string;
    : : Mark: integer;
    : : end;
    : :
    : : const
    : : MaxStudents = 20;
    : :
    : : type
    : : TStudents = array[0..MaxStudents-1] of TStudent;
    : :
    : : var
    : : Students: TStudents;
    : :
    : : procedure EditStudent(index: integer);
    : : begin
    : : { Write code to update indexth student }
    : : end;
    : :
    : : procedure ShowStudent(index: integer);
    : : begin
    : : { Write code to show indexth student's info }
    : : end;
    : :
    : : procedure ShowAllStudents;
    : : var
    : : i: integer;
    : : begin
    : : for i := 0 to MaxStudents-1 do
    : : ShowStudent(i);
    : : end;
    : : [/code]
    : :
    : dam didn't got the idea of this prog... :/
    :
    This is a start of what you asked for: an array/record-based database of student information. All you need to do now is to fill in the blanks and make it a real program.
  • triky3000triky3000 Posts: 8Member
    : : : : I need a program wich contained arrays and a little database made with record. for example make a program wich showed the marks of 5 students. Could someone help ? PLEASE...
    : : : :
    : : : Start by defining your records. Then define your array. Finally write a procedure to fill one record, show one record, show all records, etc.
    : : : [code]
    : : : type
    : : : TStudent = record
    : : : Name: string;
    : : : Mark: integer;
    : : : end;
    : : :
    : : : const
    : : : MaxStudents = 20;
    : : :
    : : : type
    : : : TStudents = array[0..MaxStudents-1] of TStudent;
    : : :
    : : : var
    : : : Students: TStudents;
    : : :
    : : : procedure EditStudent(index: integer);
    : : : begin
    : : : { Write code to update indexth student }
    : : : end;
    : : :
    : : : procedure ShowStudent(index: integer);
    : : : begin
    : : : { Write code to show indexth student's info }
    : : : end;
    : : :
    : : : procedure ShowAllStudents;
    : : : var
    : : : i: integer;
    : : : begin
    : : : for i := 0 to MaxStudents-1 do
    : : : ShowStudent(i);
    : : : end;
    : : : [/code]
    : : :
    : : dam didn't got the idea of this prog... :/
    : :
    : This is a start of what you asked for: an array/record-based database of student information. All you need to do now is to fill in the blanks and make it a real program.
    :
    :(
Sign In or Register to comment.