{'fraction_non_alphanumeric': 0.02091503267973856, 'fraction_numerical': 0.00522875816993464, 'mean_word_length': 5.627705627705628, 'pattern_counts': {'":': 0, '<': 0, '<?xml version=': 0, '>': 0, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
Two approaches to teaching software components using Ada 95

Abstract data types (ADTs) have been used for many years to teach the specification and implementation of software components. With the advent of object-oriented programming languages (OOPLs), many ADT specifications and implementations are now encoded in OOPLs as classes. OOPLs typically provide a variety of language mechanisms that support data abstraction and make classes convenient for encoding ADT specifications and implementations. In particular, the inheritance mechanism supported by OOPL classes provides useful ways of relating ADT specifications and implementations. The Ada programming language has always provided solid support for specification and implementation of ADTs with its package construct. The 1995 revision to Ada (Ada 95) added a variety of powerful new language mechanisms such as tagged types (full-fledged inheritance), abstract types, and hierarchical library units. Each of these new Ada language mechanisms, in addition to packages, can be used in various combinations to support the specification, implementation, and extension of ADTs. In this paper, we compare two approaches used to teach to second-year undergraduates specification and implementation of software components in Ada. The first approach is a traditional Ada approach relying solely on the package mechanism to support data abstraction. The second approach relies heavily on Ada's newer object-oriented language mechanisms in addition to hierarchical library units.