turbomen 0 Junior Poster

Dear All,

How do I display the pathname to the BASH shell of the Linux Terminal?

Cheers,

turbomen 0 Junior Poster

Hi,

Are there any web version of Delphi? It is because I cannot install the Delphi from my portable harddrive to the public computers.

Cheers,

turbomen 0 Junior Poster

Dear All,

Could you tell me what is / are wrong of the coding?

Cheers,

turbomen 0 Junior Poster

Dear Sir,

Thank you for your kind help and I have a new question. I have followed the demo to do the same thing but it does not work.

Please help me to have a look.

Cheers,

turbomen 0 Junior Poster

Below is an example ProjectSum about For loop using Edits and Labels:

Thank you for your help at the last time. I have tried to re-do the question by myself. Could you tell me what is wrong or missing for the attached document?

Cheers,

turbomen 0 Junior Poster

Your project works fine after I did remove a line from TonyProject1.dpr

Thank you for your kind reply but could you tell me how can I change to For Loop?

Cheers,

turbomen 0 Junior Poster

turbomen,
Could you explain, why in your Example3.zip the method procedure TForm1.Button1Click(Sender: TObject); is not assigned with the Event of Button1 OnClick ?
This is the reason your example does not work at all ....
I did upload here my example which works fine some days ago ....
May be you did not try it ?
Gud luck :!:

Dear Sir,

How can I use a For loop and a TImage components to produce the animation?

I need your help,

Cheers,

turbomen 0 Junior Poster

Sorry Sir,

The result is the same. It does not help.

Cheers,

turbomen 0 Junior Poster

I hope this helps

Hi,

I found that Delphi6 is not suitable to work on these exercises. Could you tell me what software(s) is / are suitable?

Cheers,

turbomen 0 Junior Poster

Hi FlamingClaw,

Long time no see, how are you?

Thank you for your help but it does not work as well.

Cheers,

turbomen 0 Junior Poster

Is there a specific problem that you are running into? The code works just fine with Lazarus and Delphi both.

Sorry,

I forget to attach the document.

Cheers,

turbomen 0 Junior Poster

Dear All,

Could you tell me what is wrong or missing for my coding?

Cheers,

unit Example3;

interface

uses
  Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
  Dialogs, StdCtrls;

type
  TForm1 = class(TForm)
    Edit1: TEdit;
    Edit2: TEdit;
    Edit3: TEdit;
    Edit4: TEdit;
    Edit5: TEdit;
    Button1: TButton;
    Button2: TButton;
    Edit6: TEdit;
    Edit7: TEdit;
    Label1: TLabel;
    Label2: TLabel;
    procedure Button1Click(Sender: TObject);
  private
    { Private declarations }
  public
    { Public declarations }
  end;

var
  Form1: TForm1;

implementation

{$R *.dfm}

procedure TForm1.Button1Click(Sender: TObject);
var
  sum, average: integer;
begin
  sum:=StrToInt(Edit1.Text)+StrToInt(Edit2.Text)+StrToInt(Edit3.Text)+StrToInt(Edit4.Text)+StrToInt(Edit5.Text);
  average:=sum div 5;
  Edit6.Text:=IntToStr(sum);
  Edit7.Text:=IntToStr(average);
end;

end.
turbomen 0 Junior Poster

Hi,

Thank you for your kind reply and help. But could you mind tell me why I cannot put 'for count := 1 to 10 do' to the program?

Cheers,

unit Unit2;

interface

uses
  Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
  Dialogs, ExtCtrls, StdCtrls;

type
  TForm2 = class(TForm)
    Button1: TButton;
    Image1: TImage;
    procedure Button1Click(Sender: TObject);
  private
    { Private declarations }
  public
    { Public declarations }
  end;

var
  Form2: TForm2;

implementation

{$R *.dfm}

procedure TForm2.Button1Click(Sender: TObject);
var
  count: integer;
begin
  for count := 1 to 10 do
  begin
    Image1.Picture.LoadFromFile('T'+ IntToStr(count)+'.bmp');
    sleep(100);
    update;
  end;
end;

end.
turbomen 0 Junior Poster

Dear All,

Could you tell me how to do for it? One of the zip is the demo2.zip and the other is my work.

Please give me some of the ideas.

Cheers,

turbomen 0 Junior Poster

Dear All,

Please let me know what is wrong or missing for it from the attached document. One of them is my work (T9.zip) and the other is the demo

Cheers,

turbomen 0 Junior Poster

Hi,

Thank you for your kind help but the screen is total different between Delphi6 and Delphi IDE.

Cheers,

turbomen

Hi,

I have tried to open my classwork at my computer but I do not know why I cannot change the size of the image and many of the things.

Please give me some of the ideas to do it.

Cheers,

turbomen

turbomen 0 Junior Poster

Hi,

Thank you for your kind help but the screen is total different between Delphi6 and Delphi IDE.

Cheers,

turbomen

Hi,
I could tell you how to start to VCL Forms Application using Delphi7:

You have to use menu:
- File
- New
- Application

Delphi will open a new Unit1.pas and a new Form1 ....
Unit1 will contain all the methods about Form1.
You may drop VCL-components from the palette of Delphi into Form1 as Buttons, Memos, StringGrids and so on....
After that you may develop your application by programming Events of above Components as:

procedure TForm1.Button1Click(Sender: TObject);
begin
//.............
end;

....

turbomen 0 Junior Poster

Dear ALL,

Hi. Long time no see. How are you? I have come back to Programming class already.

Could you tell me how can I start to VCL Forms Application if I use Delphi6?

Cheers,

turbomen

turbomen 0 Junior Poster

Thank you for your kind reply.

The restore kit is inside the harddrive but it does not go to the screen of Window. After discussing with the support from American Region. She advise me to buy back the restore CD from New Zealand / Australian Region. I have tried to call the 0800 phone on yesterday but it does not work because I am not in New Zealand now. When I tried to call the support of Australia. She is on a holiday in this moment until 7 January.

So, what can I do in this moment. Have you got the restore CD?

Cheers,

turbomen

turbomen 0 Junior Poster

Dear ALL,

I have bought a PC COMPAQ CQ2000AN in New Zealand. That model does not provided the restore kit in CD formation. I know the restore kit which is installed into the harddrive but now the PC was not work and cannot go to the windows screen and DOS prompt.

I have tried to call the support of HP at Australia but she is on a holiday until 7th January, 2010.

Could you tell me what I can do to solve the problem? I am not in New Zealand.

Please help

turbomen

turbomen 0 Junior Poster

Thank you for your prompt reply. Yes, I want to calculate the value of the variable (evens). Just follow the source code in my head, or on paper. But how can I do in this way?

Maybe, it is not useful for me to work on the computer for this kind of question.

turbomen 0 Junior Poster

It is the attached document.

turbomen 0 Junior Poster

Dear ALL,

Could you tell me how can I do this kind of question if I do not working with the computer and please find the attached document for your reference - it is the answer of the question?

Complete the table below to show what each variable holds, the user enters the numbers 5, 6, 7, 8, 9

evens:=0;
for count:= 1 to 5 do
    begin
      writeln('Please enter a number');
      readln(numbers[count]);
      if (numbers[count] mod 2 = 0) then
	begin
	  evens := evens + 1;
	end
    end;
writeln(evens);
turbomen 0 Junior Poster

Dear ALL,

Could you tell me what is wrong of my program? The problem is the following wording are often restart: "PLEASE RUN THIS PROGRAM IN A MAXIMUM WINDOW..., TONY YEUNG PRESENT...

How can I add some music for it? How can I change the colour of the font and display into screen?

Program yeungkt2;
{$APPTYPE CONSOLE}
{
    IT113 Assignment - Who wants to be a student millionaire.
    Author:  Tony Yeung
    Date: 16 October 2009
    Version 2.03
}
uses
  SysUtils,OurCrt;
Type
   hotSeat_record=record
   lastname  :string[12];
   firstname :string[12];
   address   :string[25];
End;

//*****************  USED VARIABLES   ******************************************
Var User_Choice    :Integer;  //global variable
    hotSeat_file  :file of hotSeat_record;
    hotSeat       :array[1..100]of hotSeat_record;
    numberRecords  :integer;
    numbers        :array[1..6] of integer;
    generate       :boolean;
    ONE            :hotSeat_record;
//********************  PROCEDURE LOAD  ****************************************
Procedure load;
Var
   count:integer;
begin
  writeln;
  writeln;
  writeln;
  writeln;
  writeln;
  writeln;
  writeln;
  writeln;
  writeln;
  writeln;
  writeln('                  PLEASE RUN THIS PROGRAM IN A MAXIMIZED WINDOW');
  writeln;
  writeln('                            PRESS <ENTER> TO CONTINUE');
  readln;
  clrscr;
  writeln;
  writeln;
  writeln;
  writeln;
  writeln;
  writeln;
  writeln;
  writeln;
  writeln;
  writeln;
  writeln('                  T');
  sleep(200);
  clrscr;
  writeln('                  TO');
  sleep(200);
  clrscr;
  writeln('                  TON');
  sleep(200);
  clrscr;
  writeln('                  TONY');
  sleep(200);
  clrscr;
  writeln('                  TONY ');
  sleep(200);
  clrscr;
  writeln('                  TONY Y');
  sleep(200);
  clrscr;
  writeln('                  TONY YE');
  sleep(200);
  clrscr;
  writeln('                  TONY YEU');
  sleep(200);
  clrscr;
  writeln('                  TONY YEUN');
  sleep(200);
  clrscr;
  writeln('                  TONY YEUNG');
  sleep(200);
  clrscr;
  writeln('                  TONY YEUNG ');
  sleep(200);
  clrscr;
  writeln('                  TONY YEUNG P');
  sleep(200);
  clrscr;
  writeln('                  TONY YEUNG PR');
  sleep(200);
  clrscr;
  writeln('                  TONY YEUNG PRE');
  sleep(200);
  clrscr;
  writeln('                  TONY YEUNG PRES');
  sleep(200);
  clrscr;
  writeln('                  TONY YEUNG PRESE');
  sleep(200);
  clrscr;
  writeln('                  TONY YEUNG PRESEN');
  sleep(200); …
turbomen 0 Junior Poster

Dear Sir,

Thank you for your help.

Cheers,

turbomen 0 Junior Poster

Hi,

Thank you for your kind reply. I am using Borland Delphi but what is TFileStream?

Cheers,

turbomen 0 Junior Poster

Dear ALL,

Could you tell me how can I write a program that writes to a text file, the 32 people that are in our hotSeat.txt file.

Cheers,

turbomen

(p.s.: 'the question orginally ask me to write a program that writes to a text file, the 32 people that are in our hotSeat.dat file' but it is not possible for me to upload the *.dat file to here. So, I have make changes of the *.dat file to *.txt file before upload it.)

turbomen 0 Junior Poster

Dear All,

Could you tell me how can I read from the hotseat.txt file all the records and sort by first name. Finally, list the sorted results on the screen.

Cheers,

turbomen

turbomen 0 Junior Poster

I am still thinking what I want to do for the coding.

It is not easy.

turbomen 0 Junior Poster

Dear Sir,

Can I do in the following way??

Program xxx;

{$APPTYPE CONSOLE}


}

uses
  SysUtils,
  OurCrt;

Type
   hotSeat_record=record
   lastname:string[12];
   firstname:string[12];
   address: string[20];
   money:longint;
End;

Var User_Choice:Integer;
  hotSeat_file:file of hotSeat_record;
  hotSeat:array[1..100]of hotSeat_record;
  numberRecords:integer;
  numbers: array[1..10] of integer;
  generate: boolean;
  players:array[1..10] of hotseat_record;

Procedure load;
Var
   count:integer;
begin
    assign(hotSeat_file,'hotSeat.dat');
    reset(hotSeat_file);
    numberRecords:= filesize(hotSeat_file);
  for count:=  1 to numberRecords do
  Begin
    read(hotSeat_file,hotSeat[count]);
  end;
end;

Procedure ContestantsList;

Var
   count:integer;

Begin
  numberRecords:= filesize(hotSeat_file);

  WriteLn;

  for count:=  1 to (filesize(hotSeat_file)) do
  Begin
  WriteLn(hotSeat[count].firstname:12,hotSeat[count].lastname:12,
  hotSeat[count].address:20);
  sleep(100);
  End;
  readln;
end;

Procedure Generate10finalists;
var
  count,temp:integer;

begin
  writeln('Here are the 10 finalist''s numbers');
  randomize;
  for count:= 1 to 10 do
  begin
    temp:=random(numberRecords)+1;
    while(temp=numbers[1])
    or (temp=numbers[2])
    or (temp=numbers[3])
    or (temp=numbers[4])
    or (temp=numbers[5])
    or (temp=numbers[6])
    or (temp=numbers[7])
    or (temp=numbers [8])
    or (temp=numbers [9])
    or (temp=numbers [10]) do
    begin
      temp:=random(numberRecords)+1;
    end;
    numbers[count]:=temp;
    generate := true;
  end;

  for count := 1 to 10 do
    begin
      writeln;
      writeln('     ***<$$$$$>****  ' ,(numbers[count]), '  ****<$$$$>****');
      writeln;
      sleep(100);
    end;
    writeln('              GOOD LUCK !!!!!!!');
    readln;
    clrscr;
end;

procedure ques(y:question;var pl:hotseat_record);
var user:char;
begin
    y.dollar:=1000;
    y.quest:='How many the price of a good laptop?';  {just example...}
    y.rightansw:='5000$';
    y.answ1:='2000$';
    y.answ2:='5000$';
    y.answ3:='7000$';
    
    {welcome the player}
    writeln('Hi ',pl.firstname);
    
    writeln(y.quest);
    writeln('a: ',y.answ1);
    writeln('b: ',y.answ2);
    writeln('c: ',y.answ3);
    readln(user);
    case (user)of
        'a':begin
                writeln('wrong answer');
                pl.money:=pl.money-y.dollar;
            end;
        'b':begin
                writeln('good answer,you get ',y.dollar,'$');
                pl.money:=pl.money+y.dollar;
            end;
        'c':begin
                writeln('wrong answer');
                pl.money:=pl.money-y.dollar;
            end;
    end;



end;



Procedure ShowFinalists;
  var
  count: integer;
  Begin
  if (generate = true)  then
  begin
    WriteLn('3 pressed,finding and listing the finalists...');
    WriteLn;
    for count:=1 to 10 do
    begin
      writeln(hotSeat[numbers[count]].firstname:12,
      hotSeat[numbers[count]].lastname:12, hotSeat[numbers[count]].address:20);
      writeln;
      sleep(200);
    end
  end
  else
      writeln('Please generate finalist …
turbomen 0 Junior Poster

Dear Sir,

Could you tell me where I want to code 'a question procedure'? May I want to code it after Procedure ShowFinalists?

Cheers,

turbomen 0 Junior Poster

Thank you for your kind help. Let me try it on tonight.

turbomen 0 Junior Poster

Dear Sir,

May I want to add the new procedure to write out the question after the coding of WriteLn(' 2 Generate the 10 finalist''s numbers'); ??

It makes me crazy.

Cheers,

turbomen 0 Junior Poster

Dear Sir,

Sorry, I did not express very well. Can you catch my meaning?

Cheers,

turbomen 0 Junior Poster

Dear Sir,

Sorry, I did not express it very well. Hm... Let me see. After the player select '2 Generate the 10 finalist's numbers. All the 10 persons can have chance to win the great price. For example, like the 'deal and no deal' game. They will be asked some of the question, when the first finalist can answer the questions, then he / she will get $100, $500, $1500, $5000, $10000, $30000, $60000, $150000, ... $1000000. If this person do not get the right answer, then, he will lost the chance and the highest prize $1,000,000 will be lost also. Next, ... until all the question have been asked, then he will get the prize. Maybe $150000.

turbomen 0 Junior Poster

It's the hotSeat.txt file.

Plese change the following line:

assign(hotSeat_file,'hotSeat.dat');

into assign(hotSeat_file,'hotSeat.txt');

turbomen 0 Junior Poster

Dear Sir,

Could you please give me some of the ideas of making the hotSeat game in pascal?

The following is the simple mode of my coding:-

Program yeungkt1;

{$APPTYPE CONSOLE}

{
    Who wants to be a millionaire.
    Author:  Chris Yeung
    Version 1
}

uses
  SysUtils,
  OurCrt;

Type
   hotSeat_record=record
   lastname:string[12];
   firstname:string[12];
   phone: string[12];
End;

Var User_Choice:Integer;
  hotSeat_file:file of hotSeat_record;
  hotSeat:array[1..100]of hotSeat_record;
  numberRecords:integer;
  numbers: array[1..10] of integer;
  generate: boolean;


Procedure load;
Var
   count:integer;
begin
    assign(hotSeat_file,'hotSeat.dat');
    reset(hotSeat_file);
    numberRecords:= filesize(hotSeat_file);
  for count:=  1 to numberRecords do
  Begin
    read(hotSeat_file,hotSeat[count]);
  end;
end;

Procedure ContestantsList;

Var
   count:integer;

Begin
  numberRecords:= filesize(hotSeat_file);

  WriteLn;

  for count:=  1 to (filesize(hotSeat_file)) do
  Begin
  WriteLn(hotSeat[count].firstname:12,hotSeat[count].lastname:12,
  hotSeat[count].phone:20);
  sleep(100);
  End;
  readln;
end;

Procedure Generate10finalists;
var
  count,temp:integer;

begin
  writeln('Here are the 10 finalist''s numbers');
  randomize;
  for count:= 1 to 10 do
  begin
    temp:=random(numberRecords)+1;
    while(temp=numbers[1])
    or (temp=numbers[2])
    or (temp=numbers[3])
    or (temp=numbers[4])
    or (temp=numbers[5])
    or (temp=numbers[6])
    or (temp=numbers[7])
    or (temp=numbers [8])
    or (temp=numbers [9])
    or (temp=numbers [10]) do
    begin
      temp:=random(numberRecords)+1;
    end;
    numbers[count]:=temp;
    generate := true;
  end;

  for count := 1 to 10 do
    begin
      writeln;
      writeln('     ***<$$$$$>****  ' ,(numbers[count]), '  ****<$$$$>****');
      writeln;
      sleep(100);
    end;
    writeln('              GOOD LUCK !!!!!!!');
    readln;
    clrscr;
end;





Procedure ShowFinalists;
  var
  count: integer;
  Begin
  if (generate = true)  then
  begin
    WriteLn('3 pressed,finding and listing the finalists...');
    WriteLn;
    for count:=1 to 10 do
    begin
      writeln(hotSeat[numbers[count]].firstname:12,
      hotSeat[numbers[count]].lastname:12, hotSeat[numbers[count]].phone:20);
      writeln;
      sleep(200);
    end
  end
  else
      writeln('Please generate finalist number first!');
    readln;
  End;

Procedure save;
  var
  count: integer;
  Begin
    reset(hotSeat_file);
    for count:=1 to filesize(hotSeat_file) do
      begin
       write(hotSeat_file,hotSeat[count]);
      end;
  end;


Procedure ChangeDetails;
  var
  count: integer;
  firstname,lastname,newphone: string[12];
  name: …
turbomen 0 Junior Poster

Dear ALL,

I have tried to demonstrate the card game problem by myself. The card game is come together with 52 cards. It has Spade, Heart, Club and Diamond - Spade > Heart > Club > Diamond. It has the integers and chars 2,3,4,5,6,7,8,9,10,J,Q,K,A. Could you tell me how can I code this program if we only play for 5 times. We choose 1 card in every time randomly.

Cheers,

turbomen

turbomen 0 Junior Poster

How about if the card game has the numbers 2,3,4,5,6,7,8,9,10,J,Q,K,A. Are there any changes of the program?

turbomen 0 Junior Poster

Could you mind telling me what can I do for the following question?

To write a skeleton program for the assignment. It should have a menu system with at least 5 options. The menu keeps repeating after each procedure is called. When one of the procedures is called just return a message to the screen saying what this procedure will do: ie “this is task 1”

The menu options are:
1 Task 1
2 Task 2
3 Task 3
4 Task 4
0 Exit menu system


(Hint: use a case statement)


Cheers,

turbomen 0 Junior Poster

Thank you for your clear expression. Are there any changes if the card game has 52 cards?

turbomen 0 Junior Poster

Dear Sir,

Could you tell me how can I do the following question?

A positive integer is entered from the keyboard. If it's even, all even integers from 2 up to and including the entered integer are displayed. If odd, all odd integers from 1 up to and including the entered integer are summed, and the sum displayed.

For example if the number entered was 20, the display would be:
2 4 6 8 10 12 14 16 18 20
Alternatively, if the number entered was11, the display should be:
36

Cheers,

turbomen 0 Junior Poster

Dear Sir,

Sorry, I forget to mention about the cards and the rule of it.

It is come together with 52 cards, from A, K, Q, J, 10, 9, 8, 7, 6, 5, 4, 3, 2. and Spade > Heart > Club > Diamond.

Cheers,

turbomen 0 Junior Poster

Dear All,

Could you mind telling me how to code with the card game? It has 52 cards and it comes together with Spade, Heart, Club and Diamond. There are 2 people play together for 8 times, after it, we will get the result of it.

Cheers,

turbomen 0 Junior Poster

Dear Sir,

I have some of the problem to catchup your problem. Would you mind expressing it again?

Cheers,

turbomen 0 Junior Poster

Dear Sir,

I know what I do not understand. It is the coding between both parties. For example when I code RPS, guessing games, Head & Tail are only one part of the parties are random. But both parties need to clip randomly in this time.

Cheers,

turbomen 0 Junior Poster

1. Yes, I do. But my coding is not for randomly. Could you tell me how to do it?

2. I know how to do this part. Thank you.

Dear Sir,

Would you mind showing it to me clearly? I cannot catch it up.

Cheers,

turbomen 0 Junior Poster

Dear Sir,

I have made a question by myself. For example: I am playing the card game to my friend. The card has Spade, Heart, Club and Spade as usual but no number. How can I do if I only play five time and finally there is a record of the comparison XX : XX.

The following is my answer:

program Spade;

{$APPTYPE CONSOLE}

uses
  SysUtils;

var
        Count, Num, Computer : integer;
        Choice, compChar : char;

begin
   Num:=0;
   Computer:=0;

randomize;
   for Count:=1 to 5 do
   repeat
     writeln('Welcome to play the game of Spades');
     readln(Choice);
   until (Choice = 'S') or (Choice = 'H') or (Choice = 'C') or (Choice = 'D');

case Choice of
'S': writeln('You have got Spade');
'H': writeln('You have got Heart');
'C': writeln('You have got Club');
'D': writeln('You have got Diamond');
end;

Computer:= random(4);

case Computer of
0:
begin
  writeln('Computer have chosen Spade');
  compChar:= 'S';
end;
1:
begin
  writeln('Computer have chosen Heart');
  compChar:= 'H';
end;
2:
begin
  writeln('Computer have chosen Club');
  compChar:= 'C';
end;
3:
begin
  writeln('Computer have chosen Diamond');
  compChar:= 'D';
end;

end;

  if ((Choice='S') and (compChar='H') and (compChar='C') and (compChar='D')) or ((Choice='H') and (compChar='C') and (compChar='D')) or ((Choice='C') and (compChar='D')) then
  begin
    writeln('You win');
  end
  else
    if ((Choice='S') and (compChar='S')) or ((Choice='H') and (compChar='H')) or ((Choice='C') and (compChar='C')) or ((Choice='D') and (compChar='D'))  then
    begin
      writeln('You draw');
    end
    else
      writeln('You loss');
      readln;
end.

But how can I do if I want to make changes to choose randomly?

turbomen 0 Junior Poster

Dear ALL,

I still got some of the problem on the understand of the following coding:

program RPSii;

{$APPTYPE CONSOLE}

uses
  SysUtils;

var
        Computer : integer;
        Choice, compChar : char;

begin

randomize;
   repeat
     writeln('Welcome to play the game of Rock(R), Paper(P), Scissors(S)');
     readln(Choice);
   until (Choice = 'R') or (Choice = 'P') or (Choice = 'S');

case Choice of
'R': writeln('You have chosen Rock');
'P': writeln('You have chosen Paper');
'S': writeln('You have chosen Scissors');
end;

Computer:= random(3);

case Computer of
0:
begin
  writeln('Computer have chosen Rock');
  compChar:= 'R';
end;
1:
begin
  writeln('Computer have chosen Paper');
  compChar:= 'P';
end;
2:
begin
  writeln('Computer have chosen Scissors');
  compChar:= 'S';
end;
end;

  if ((Choice='R') and (compChar='S')) or ((Choice='P') and (compChar='R')) or ((Choice='S') and (compChar='P')) then
  begin
    writeln('You win');
  end
  else
    if ((Choice='R') and (compChar='R')) or ((Choice='P') and (compChar='P')) or ((Choice='S') and (compChar='S'))  then
    begin
      writeln('You draw');
    end
    else
      writeln('You loss');
      readln;
end.
turbomen 0 Junior Poster

Dear Mehrdad Nekoei and all the brothers

Thank you for your help on this program. Could you tell me what is the meaning of 1-3 at the case statement? I have tried to revise the order 3,2,1 but I can get the answer.

Cheers,