comp.lang.ada
 help / color / mirror / Atom feed
From: Mike H <postmaster@ada-augusta.demon.co.uk>
Subject: Re: Reading data from file
Date: Wed, 5 Mar 2014 13:59:43 +0000
Date: 2014-03-05T13:59:43+00:00	[thread overview]
Message-ID: <u4odG4BP3yFTFwZb@ada-augusta.demon.co.uk> (raw)
In-Reply-To: 9b780534-04fb-43c8-b8de-1610421c471d@googlegroups.com

In message <9b780534-04fb-43c8-b8de-1610421c471d@googlegroups.com>, 
Laurent <daemon2@internet.lu> writes
>Here is my code. It compiles but it isn't complete.

 From what I see of your code so far, it is going to fail if any of the 
data in the input file is corrupt. Do not take that as a criticism 
because, depending upon the requirements as set out in the exercise you 
are attempting, it may be quite acceptable. In which case you have 
nothing to worry about.

But in the real world corrupt data is an inevitability. If you don't 
believe me, try putting a non-numeric character in the "ID" line. By 
it's very nature, corrupt data is chaotic. Trapping and reporting such 
errors and then recovering from that situation and dealing with further 
data (whether corrupt or not) takes a certain amount of skill. It also 
involves writing a considerable amount of code, which by definition, one 
hope will never need to be executed.

-- 
Time flies like an arrow. Fruit flies like a banana.
Mike

  parent reply	other threads:[~2014-03-05 13:59 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-03-04  9:46 Reading data from file Laurent
2014-03-04 16:17 ` adambeneschan
2014-03-04 18:08 ` Mike H
2014-03-04 21:27   ` Laurent
2014-03-04 21:35     ` Laurent
2014-03-04 21:42     ` Niklas Holsti
2014-03-05 13:59     ` Mike H [this message]
2014-03-05 20:33       ` Laurent
2014-03-05 21:00         ` Jeffrey Carter
2014-03-05 21:13           ` Laurent
2014-03-05 21:25             ` Niklas Holsti
2014-03-05 21:56               ` Laurent
2014-03-06  8:35                 ` Dmitry A. Kazakov
2014-03-07 21:55                   ` Laurent
2014-03-08  6:56                     ` Dmitry A. Kazakov
2014-03-08 21:21                       ` Laurent
2014-03-09 22:39                         ` Laurent
2014-03-10  2:42                           ` Jeffrey Carter
2014-03-11 20:54                             ` Laurent
2014-03-08  9:00                     ` Simon Wright
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox