Learn the basics of the general purpose Ada programming language. Learning Ada can be fun and valuable in its own right, but its unique approach can make you a better programmer in languages you already know.
This course will introduce you to the basics of the Ada language. It will cover concepts that were present in the Ada 83 release but also include features from the current Ada 2012 version. In this course, you'll start with downloading and installing a free and highly capable toolchain for Ada. Then you'll learn the basic concepts and syntax of the language including types/subtypes, expressions, procedures, functions, and packages. By the end of the course, you'll be creating useful applications and kicking yourself for ignoring this powerful and constantly evolving language for so long.
Subprograms Welcome to the module on subprograms. I'm Tod Gentille from Pluralsight. In this module, we'll be discussing Scope, Functions, and Procedures. The distinction in Ada is that functions return a value and procedures do not. In either case, the body of the subprogram executes, just like the code we've been seeing. Of course, you can pass in parameters, and in Ada you can even specify the mode of those parameters, that is you can specify whether a parameter is an input, an output, or an input output. Just like aggregates, subprogram parameters can be specified by position or name. Parameters also support default values. From the sneak peek we got at generic programming in Ada, you've probably guessed that Ada subprograms also support overloading. That is, if the number, order, and type of parameters isn't the same, then the subprograms can all have the same name and Ada will know which one to call. Furthermore, functions can't hide procedures, so you could have a function and a procedure with identical names that take no parameters and Ada will properly disambiguate them. We'll get to all this and more in this module, but in the next clip let's delve into scope and talk about nested blocks in Ada.