|
DataMuseum.dkPresents historical artifacts from the history of: RegneCentralen RC700 "Piccolo" |
This is an automatic "excavation" of a thematic subset of
See our Wiki for more about RegneCentralen RC700 "Piccolo" Excavated with: AutoArchaeologist - Free & Open Source Software. |
top - download
Length: 768 (0x300) Types: TextFile Names: »UPCASE.PAS«
└─⟦09235ab48⟧ Bits:30003065 Demoprogrammer K-Z til Pascal bog └─ ⟦this⟧ »UPCASE.PAS«
PROGRAM upcase; TYPE str40 = STRING(.40.); VAR streng : str40; FUNCTION uppercase(str : str40) : str40; VAR i : INTEGER; s : str40; BEGIN (* uppercase *) s := ''; FOR i := 1 TO LEN(str) DO IF ('a' <= str(.i.)) AND (str(.i.) <= 'å') THEN s := s + CHR(ORD(str(.i.)) - 32) ELSE s := s + str(.i.); uppercase := s; END; (* uppercase *) BEGIN (* upcase *) WRITE(CLRHOM); REPEAT WRITE('Indtast en tekst (ingen tekst stopper): '); BUFLEN := 40; READLN(streng); WRITELN('''', streng, ''' kan også skrives: '); WRITELN(uppercase(streng)); WRITELN; UNTIL (streng = ''); END. (* upcase *) «eof»