home *** CD-ROM | disk | FTP | other *** search
- From: hemstree@mddchh.fc.hp.com (Charles H. Hemstreet IV)
- Date: Tue, 29 Dec 1992 16:12:53 GMT
- Subject: How forgiving is TURBO pascal concerning strings?
- Message-ID: <HEMSTREE.92Dec29091253@mddchh.mddchh.fc.hp.com>
- Organization: Hewlett Packard - Mechanical Design Division
- Path: sparky!uunet!usc!sdd.hp.com!hpscit.sc.hp.com!hplextra!hpfcso!hpfcmdd!hpfcmdd.fc.hp.com!hemstree
- Newsgroups: comp.lang.pascal
- Sender: news@hpfcmdd.fc.hp.com (News)
- Lines: 31
-
-
- With the following brief description below what is the expected result?
- Will Turbo pass by the comparison without an error? I am also
- assuming that teststr[0] contains the value of the size of the string.
-
- Thank you for any help,
-
- Charles
-
- ------------------
- teststr : string[100];
- testchar : char;
-
- teststr := 'the is not a big string';
- testchar := 'a';
-
- if testchar = teststr[0] then make a milkshake
- else milk the cow first
- ------------------
- --
- Charles
-
- -------------------------------------------------------------------------------
- Charles H. Hemstreet IV ******** h *******
- Hewlett Packard /\ /\ ******* h *****
- 3404 East Harmony Rd., MS110 /\/ \ /\ / \ ***** hhhh pppp ****
- Ft. Collins, CO 80525 /\/ \ \/ \/\/ \ **** h h p p ****
- (303) 229-4471 / \ \ / / \ \ **** h h pppp *****
- (303) 229-7182 (fax) / \ \ / \ \ ***** p *******
- hemstree@mddchh.fc.hp.com Mech. Design Division ******* p ********
- -------------------------------------------------------------------------------
-