Thursday, September 18th 2025, 8:36pm UTC+2

You are not logged in.


Date of registration: Jun 16th 2002

Posts: 2,389

Bike: Aprilia RS 2002 SBK Kaputt; KTM Duke II 2002 Verkauft; Audi A3

Location: Ingelheim bei Mainz

1

Thursday, July 3rd 2003, 7:13pm

Free-Pascal !! HILFE !?

also hallo !!

ich hab morgen in der 5. und 6. stunde informatik ...

und morgen sollen wir mit einem programm fertig sein ...

der arbeitsauftrag lautet :

Ein kleines Hotel mit 10 Zimmer kann entweder belegt sein oder nicht ! Gib aus welches Zimmer belegt ist und welches nicht !

ich hab bis jetzt so nen anfang :

Program Hotel

uses crt;

Type t_zimmer : Array[1..10] of Boolean;
VAR i : = INTEGER;
f := Boolean;

weiss nicht ob die Variablen jetzt so richtig deklariert sind...

jetzt soll halt mit Boolean zufällig bestimmt werden welches Zimmer belegt ist und welches nicht...

das heißt wir sollen ein Programm schreiben wo ein Kunde ankommt und sagt welches Zimmer er belegen will z.B.:

writeln('welches Zimmer möchten sie reservieren: ');
readln(i);

und dann soll nochmal nachgefragt werden wenn dieses Zimmer frei ist, ob es wirklich reserviert werden soll und dann soll ausgegeben wenn ja, dann soll das Programm schreiben" Dieses Zimmer ist jetzt belegt!" oder wenn es schonn belegt ist, soll es schreiben "Dieses Zimmer ist schonn belegt, andere Zimmernummer eingeben!" und dann halt wieder dasselbe Spiel ...

kann mir irgendjemand helfen ??

das wäre so korrekt von euch ...

weil ich komm einfach nicht weiter...

was halt wichtig ist, dass dieser Type irgendwie da drin vorkommt, weil wir das grad machen ...
09.05.2007 ;( Ich kann es einfach nicht fassen. Papa du fehlst mir ;(

07.09.03 :( My BeSt FrIeNd I WiLL NeVeR FoRgEt YoU :( 07.09.03
  • Go to the top of the page

Date of registration: Jun 16th 2002

Posts: 2,389

Bike: Aprilia RS 2002 SBK Kaputt; KTM Duke II 2002 Verkauft; Audi A3

Location: Ingelheim bei Mainz

2

Thursday, July 3rd 2003, 8:07pm

hat wirklich keiner ne Idee ?? :rolleyes:
09.05.2007 ;( Ich kann es einfach nicht fassen. Papa du fehlst mir ;(

07.09.03 :( My BeSt FrIeNd I WiLL NeVeR FoRgEt YoU :( 07.09.03
  • Go to the top of the page

Date of registration: Mar 29th 2002

Posts: 562

Bike: KTM LC4 640 SM '05

Location: Wettingen[AG] - Schweiz

3

Thursday, July 3rd 2003, 8:29pm

mit C könnt ich dir helfen aber pascal...keine ahnung. guck doch mal auf em inet ob du ein ähnliches beispiel findest....gibts sicher genung Pascal sites
  • Go to the top of the page

Date of registration: Jun 16th 2002

Posts: 2,389

Bike: Aprilia RS 2002 SBK Kaputt; KTM Duke II 2002 Verkauft; Audi A3

Location: Ingelheim bei Mainz

4

Thursday, July 3rd 2003, 8:43pm

jo dachte nur, dass hier sich jemand gut auskennst und das programm schnell schreibe könnte...
09.05.2007 ;( Ich kann es einfach nicht fassen. Papa du fehlst mir ;(

07.09.03 :( My BeSt FrIeNd I WiLL NeVeR FoRgEt YoU :( 07.09.03
  • Go to the top of the page

Date of registration: Feb 15th 2002

Posts: 2,277

Bike: Ducati 600SS

Location: Bern, Schweiz

5

Thursday, July 3rd 2003, 10:03pm

Also die Deklarationen ohne das "="

var

i : int;
f: Boolean;

Dann musst du halt nach der Eingabe aus dem Array lesen. Wenn es besetzt ist kann er es nicht mehr reservieren:

while(t_zimmer)
begin
writeln('Das Zimmer ist bereits besetzt');
writeln('welches Zimmer möchten sie reservieren: ');
readln(i);
end

t_zimmer[i] := TRUE;
writeln('Sie haben das Zimmer %d jetzt reserviert', i);


So in dem Stil...sorry bin gerade extrem müde ich kann nicht mehr. Ich hoffe ich konnte dir wenigstens einen kleinen Input geben ;)
  • Go to the top of the page

Date of registration: Jun 16th 2002

Posts: 2,389

Bike: Aprilia RS 2002 SBK Kaputt; KTM Duke II 2002 Verkauft; Audi A3

Location: Ingelheim bei Mainz

6

Friday, July 4th 2003, 2:26pm

jo trotzdem danke...haben heut das programm doch nur weitergeschrieben und war so ca. in dem stil...halt sau komplex...

DANKE Nochmal...
09.05.2007 ;( Ich kann es einfach nicht fassen. Papa du fehlst mir ;(

07.09.03 :( My BeSt FrIeNd I WiLL NeVeR FoRgEt YoU :( 07.09.03
  • Go to the top of the page

Date of registration: Feb 15th 2002

Posts: 2,277

Bike: Ducati 600SS

Location: Bern, Schweiz

7

Friday, July 4th 2003, 9:53pm

kein Problem ;)
  • Go to the top of the page

Date of registration: May 9th 2002

Posts: 2,280

Bike: KTM LC4 400 EGS (Bj. '97)

Location: Fünfseenland

8

Friday, July 4th 2003, 10:10pm

Quoted

Original von Underkill
jo trotzdem danke...haben heut das programm doch nur weitergeschrieben und war so ca. in dem stil...halt sau komplex...

DANKE Nochmal...

:)) :)) :))
sorry... das musste einfach sein...
To Do Is To Be (Nietzsche)
To Be Is To Do (Kant)
Do Be Do Be Do (Sinatra)
Fotografie Portfolio & Facebook Fanpage
  • Go to the top of the page

Rate this thread