Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!sdd.hp.com!wuarchive!udel!sbcs!libserv1.ic.sunysb.edu!jallen From: jallen@libserv1.ic.sunysb.edu (Joseph Allen) Newsgroups: comp.lang.misc Subject: Re: Formal definitions (Re: ada-c++ productivity) Message-ID: <1991Apr13.022129.29607@sbcs.sunysb.edu> Date: 13 Apr 91 02:21:29 GMT References: <1755@optima.cs.arizona.edu> <50453@nigel.ee.udel.edu> Sender: usenet@sbcs.sunysb.edu (Usenet poster) Organization: State University of New York at Stony Brook Lines: 27 In article <50453@nigel.ee.udel.edu> new@ee.udel.edu (Darren New) writes: >For example, your customer gives you the following requirements: >1) a phone will not ring if it is off-hook. >2) a phone will ring if it is on-hook and its number is dialed. >3) a non-ringing phone will issue a dialtone if off-hook and no > digits have been dialed. >4) a phone which has had 7 digits dialed will emit either a ring signal > or a busy signal. >5) ring signals will never be associated with phones which are not ringing. > etc etc etc >Clearly, this is the kind of specification a customer wants to give. :-) Yeah. (Do you work in the real world (tm)?) If customers could give this good of a specification we probably really could automate coding and we would all be out of a job. -- #define h 23 /* Height */ /* jallen@ic.sunysb.edu (129.49.12.74) */ #define w 79 /* Width */ /* Amazing */ int i,r,b[]={-w,w,1,-1},d,a[w*h];m(p){a[p]=2;while(d=(p>2*w?!a[p-w-w]?1:0:0)|( p