A Functional Specfication for a Programming Language for Computer Aided Learning Applications