#!/usr/bin/env perl
use strict;
use warnings;
use Student;

$Student::DEBUG = 1;

my $oldTA = create Student('Michael Stark', '768319810');
my $newTA = Student->create('Paul Faria', '123456789');

print "Setting ", $oldTA->name, "'s GPA...\n";
$oldTA->GPA(95.32);
print "$oldTA has a GPA of ", $oldTA->GPA, "\n";

print "About to change $newTA\'s name:\n";
$newTA->name('Matt O\'Brien');
print "New TA now: $newTA\n";

#Using an invalid GPA, should get a warning, and have GPA set to 0
$oldTA->GPA('65..32');
print "$oldTA is currently ", $oldTA->status, "\n";

print "We currently have ", Student->students, " students\n";

{
  print "About to create a new student\n";
  my $stud = create Student('Temp Testerson', '000000000');
  print "$stud created, new total: ", Student->students, "\n";
}

print "And after the block, total: ", Student->students, "\n";

