comp.lang.ada
 help / color / mirror / Atom feed
* have 2 problems, please help.
@ 2001-12-04 19:59 Ralph Moeritz
  2001-12-04 20:08 ` Ted Dennison
  2001-12-04 20:38 ` Preben Randhol
  0 siblings, 2 replies; 8+ messages in thread
From: Ralph Moeritz @ 2001-12-04 19:59 UTC (permalink / raw)


Hi all!

I've currently got 2 small problems, please help me!

1. I need GNU make for Linux (on it's own, I don't want to download it as 
part of gcc package) in order to install GNAT (I think it's dumb that GNAT 
comes with gcc and g++ but not make!), please can someone give me a www 
address where I can find it?

2. I've just completed my solution to AdaTutor outside assignment 2 and 
because I cannot compile and link my program due to problem 1. , I was 
hoping someone who has done the AdaTutor course could tell me whether my 
answer is correct or not. Source below.

Thanks!
Ralph

-- My solution to outside assignment 2 
separate (Tritest)
function Tritype(Len1, Len2, Len3 : in Integer) return Triangle is
  Answer : Triangle;
begin
  
  case Len1 > 0 is
    when 'True' =>
      if Len1 = Len2 and Len1 = Len3 then 
        Answer := Equilateral;
      elsif Len1 = Len2 and Len3 > 0 then
        Answer := Isosceles;
      elsif Len1 = Len3 and Len3 > 0 then
        Answer := Isosceles;
      elsif Len2 = Len3 and Len2 > 0 then
        Answer := Isosceles;
      elsif Len2 > 0 and Len3 > 0 then
        Answer := Scalene;
      else
        Answer := Not_A_Triangle;
      end if;
    when 'False' =>
      Answer := Not_A_Triangle;
  end case;
  
  return Answer;
end Tritype;


-- 
The War of the Ring -> http://wotr.sourceforge.net



^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2001-12-07 14:40 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-12-04 19:59 have 2 problems, please help Ralph Moeritz
2001-12-04 20:08 ` Ted Dennison
2001-12-04 20:15   ` Ralph Moeritz
2001-12-04 20:38     ` Ted Dennison
2001-12-05  3:28   ` Robert Dewar
2001-12-04 20:38 ` Preben Randhol
2001-12-04 20:45   ` Ralph Moeritz
2001-12-07 14:40     ` Preben Randhol

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