220 likes | 410 Views
A Programming Learning Environment "AZUR" : Visualizing Block Structures and Program Function Behavior . Graduate School of Engineering, Shibaura Institute of Technology ○ Toshiyuki Imaizumi Hiroaki Hashiura Saeko Matsuura Seiichi Komiya. Table of contents. background
E N D
A Programming Learning Environment "AZUR" : Visualizing Block Structures and Program Function Behavior Graduate School of Engineering, Shibaura Institute of Technology ○Toshiyuki Imaizumi Hiroaki Hashiura Saeko Matsuura Seiichi Komiya Shibaura Institute of Technology Toshiyuki Imaizumi
Tableofcontents • background • the function that AZUR aims • control structure and program function • visualization approach • demonstration • experiment • futurework • conclusion Shibaura Institute of Technology Toshiyuki Imaizumi
Background • Problem of beginners • not to understand concept of the programming • misunderstand the meaning of syntax • cannot understand the cause of error alone. →lack of teacher, enough education is not done • Flow of programming education grammar of the programming language Basic algorithm Propose program learning environment AZUR for C language Application development Shibaura Institute of Technology Toshiyuki Imaizumi
the function that AZUR aims • visualizevariousconceptofprogramming • variable, controlstructure,function,various data type(array,struct, pointer) • can choose visualization • it is probable that user want to watch pointer only, not need array and struct • can training various errors to fix alone • compilation error and debugging with debugger • grasp the learning context • discover the person who cannot fix error as the first purpose, I want that beginners can trace the execution process on the desk Shibaura Institute of Technology Toshiyuki Imaizumi
problem when beginner understand control structure • nested control structure is difficult to understand for(i=0;i<n;i++){ for(j=0;j<n;j++){ printf(“hoge”); } printf(“piyo”); } printf(“fuga”); • necessary support • to clarify execution range, show correspondence of control structure and sourcecode • to show how actually moves, execute step by step • to show reason of movement, show correspondence of control structure and actual execution After inside loop finish, where do execution go? When is this increment executed? Which for-statement include or not? Shibaura Institute of Technology Toshiyuki Imaizumi
how I should visualize control structure • [Hasegawa 98] investigate movement image of iteration that beginner have. • result of investigation • who had image are more understand execution process • loop type had better result than the other images 12…n 12… n count up type stairs type loop type • When control structure is nested, stairs type and count up type are difficult to think about movement image→ necessary to visualize by hierarchical form Shibaura Institute of Technology Toshiyuki Imaizumi
visualization of control structure • correspondence of source code and control structure and the actual execution for for for(i=0;i<n;i++){ for(j=0;j<n;j++){ printf(“hoge”); printf(“hogege”); } printf(“piyo”); } printf(“fuga”); Shibaura Institute of Technology Toshiyuki Imaizumi
visualization of recursive function call • Iwant to visualize the behavior of function call • actual argument is copied by formal argument • stacked to a stackframe and release • return a value to caller • make image of stackframe sum sum if if int sum(int n){ int s = n--; if(n > 0){ s += sum(n); } return s; } return 6 Shibaura Institute of Technology Toshiyuki Imaizumi
function of AZUR • visualization • visualize control structure and function • real-time visualize structure when coding • can change visualization with tab • IDE function • run, step in, step over, automatic step • show referred variable in next line and changed variable just before • show line and variable value when run-time error occurred • automatic compilation error check and highlight Shibaura Institute of Technology Toshiyuki Imaizumi
demonstration Shibaura Institute of Technology Toshiyuki Imaizumi
constitution of AZUR teacher compilation error help server log server step,run ,success and fail compile with source code,runtime-error debugger(gdb) .exe file learner compiler (gcc) AZUR (implemented in Java) generate Shibaura Institute of Technology Toshiyuki Imaizumi
experiment • participants • second grader 43 people of the design department of engineering of Shibaura Institute of Technology • takes the class of C language for a half term • studying a class of algorithm practice from now on • they used AZUR by this class • experiment • give 4 source codes and let them write execution process by before the class and after the class example of experiment Shibaura Institute of Technology Toshiyuki Imaizumi
resultofexperiment(1) Shibaura Institute of Technology Toshiyuki Imaizumi
result of experiment(2) Shibaura Institute of Technology Toshiyuki Imaizumi
result of F-test(1) • carryoutF-testfor 41 participants who attended at before the class and after the classtogether • compare result of the experiment with number of step execution • considered that the person who performed step execution used visualization, too • number of step is counted by the unity that continued 1.nested if-statement 2.nested for-statement Shibaura Institute of Technology Toshiyuki Imaizumi
result of F-test(2) 4.recursive function call 3.function call Shibaura Institute of Technology Toshiyuki Imaizumi
discussion • at all experiment, participants who become correctanswer are more stepped average than not become correct answer. • null hypothesis is dismissed with probability less than 5% about the recursive function → it was effective in a result by using AZUR • about the for-statement, variance hardly has a difference • visualization is insufficient? • change of the shape is necessary? Shibaura Institute of Technology Toshiyuki Imaizumi
related work visualize of the control structure • Avis[Kita 05] • converts code into flow chart • →cannot correspond code andcontrol structure,andcan't clarify execution range • [Shinkai 08] • visualized hierarchically • can execute step by step • support pseudo language only • → cannot support switchstatement and for-statement Shibaura Institute of Technology Toshiyuki Imaizumi
related work visualize of the program function • ETV[Terada 05] • when function called, open editor aside • can clarify where it was called → not show return value • Jeliot3[Moreno 04] • can show the giving and receivingof the argument and return value • can expression evaluation • effective for-statement • → there are many elements to one screens, itbecomeblinder Shibaura Institute of Technology Toshiyuki Imaizumi
Future work • whole AZUR • cooperate with compilation error support system and error insertion system • develop real-time log analysis system • change of shape • make differences such as selection and iteration, while and do-while and for-stmt • show loop edge,loopcount • add program function visualization • relation of formal arg and actual arg • scope of variable • assignment of return value • visualizevariable and type Shibaura Institute of Technology Toshiyuki Imaizumi
Conclusion • I developed AZUR which visualize the concept of the programming • Visualization is change possibility in a tab • I regard teacher support and self-learning support • visualize control structure and function for understand execution process • clarifyexecution range • show correspond actual execution and control structure • AZUR is effective for recursive function Shibaura Institute of Technology Toshiyuki Imaizumi
Thank you very much for kind attention Shibaura Institute of Technology Toshiyuki Imaizumi