Comment

Comment by ardit33

It was my first language i learned in school... in Radford ( Virginia), before my university switched to Java. ADA was/is popular with defense contractors, so a lot of schools in VA teach it.

It is very safe language, being both static typed, and strong typed. It was originally a procedural language, but later they added some OO to it. (to folks that don't know what a imperative language is, think of a language where all methods are like Java Static methods, and you store data in some global space).

It can get a bit wordy to program with it, but I also like the lack of '{' bracket use everywhere that C like syntax has. With some modifications, ADA can be transformed into a great/fun language.

Anyway, due to its small echosystem and adoption, I think it will remain a 'defense/aeronautic industry' only type of language.

This is a simple program, and I think it is fairly elegant, but a bit wordy:

  with Ada.Text_IO; use Ada.Text_IO;
  with Ada.Integer_Text_IO; use Ada.Integer_Text_IO;

  procedure Check_Positive is
     N : Integer;
  begin
     Put ("Enter an integer value: ");  -- Put a String
     Get (N);  --  Read in an integer value
     if N > 0 then
        Put (N);  --  Put an Integer
        Put_Line (" is a positive number");
     end if;
  end Check_Positive;
parent ardit33 6 years ago

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton