A new Approach for Implementing stand-alone and web-based Interpreters for Java
Compared to imperative programming languages like Pascal or Basic, or functional programming languages like ML or Haskell learning Java is hampered by the fact that to get even the simplest running program the learner has to define a public class and a method with a certain signature. We present both a stand-alone and a web-based interpreter which execute Java fragments and relieve the learner from programming all the extra code. The implementation of these interpreters extremely differs from other Java interpreters and exploits the Java compiler as much as possible to preserve the original semantics of Java and allow access to all features and APIs of Java. By virtue of these interpreters the learner can explore primitive values, variables, expressions, assignments, and control-flow statements before even knowing about classes and methods. The web-based interpreter has been integrated into an online tutorial for learning Java programming from basic principles.
Right from the start Sun was marketing Java as a simple, object-oriented programming language [3]. But object-orientation hinders to learn Java step-by-step from basic principles, because right from the beginning the learner has to define at least one public class with a method with signature public static void main( java.lang.String[]).
So the teacher has two choices here: trying to explain most of the concepts involved (classes, methods, types, arrays,…) or just provide the surrounding program text and let the learner add code to the body of the method main.
Get pdf download A new Approach for Implementing stand-alone and web-based Interpreters for Java
Related Tutorial
Tags: apis, arrays, control flow statements, functional programming languages, haskell, imperative programming languages, java compiler, java interpreters, java lang, learner, learning java programming, new approach, object orientation, object oriented programming, object oriented programming language, oriented programming language, primitive values, right from the beginning, semantics, two choices
Comments
Leave a Reply