| delorie.com/archives/browse.cgi | search |
| Message-ID: | <360D5D93.499C3AED@cdworld.co.uk> |
| From: | Craig Rothwell <craig AT cdworld DOT co DOT uk> |
| Reply-To: | craig AT cdworld DOT co DOT uk |
| Organization: | www.CDworld.co.uk |
| MIME-Version: | 1.0 |
| Newsgroups: | comp.os.msdos.djgpp |
| Subject: | fast way to do a if statement |
| Date: | Sat, 26 Sep 1998 22:33:08 +0100 |
| NNTP-Posting-Host: | 195.102.195.32 |
| NNTP-Posting-Date: | Sat, 26 Sep 1998 22:28:56 BST |
| Lines: | 16 |
| To: | djgpp AT delorie DOT com |
| DJ-Gateway: | from newsgroup comp.os.msdos.djgpp |
I have a little program I have writen to decode something but most of the program is taken up with: if (x==1) do... if (x==2) do... if (x==3) do... if (x==4) do... if (x==5) do... etc... That goes on for about 40 lines. Is there a way to do it quicker that would mean less messing about for the CPU?
| webmaster | delorie software privacy |
| Copyright © 2019 by DJ Delorie | Updated Jul 2019 |