Advertisement
electricmaster

getScore()

Jan 23rd, 2015
317
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Delphi 0.42 KB | None | 0 0
  1. function getScore(data: people): people;
  2. var
  3.   i: integer;
  4. begin
  5.   for i := 1 to length(data) do begin
  6.     data[i].chevyScore := CHEVY*data[i].chevorlet;
  7.     data[i].buickScore := BUICK*data[i].buick;
  8.     data[i].vanScore := MINI*data[i].minivan;
  9.     data[i].truckScore := TRUCK*data[i].truck;
  10.     data[i].score := data[i].chevyScore+data[i].buickScore+data[i].vanScore+data[i].truckScore;
  11.   end;
  12.   Result := data;
  13. end;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement