The Effect of Turtle Graphics Approach on Students ' Motivation to Learn Programming : A Case Study in a Malaysian University

Computer programming is not an easy subject to learn or teach, particularly to first-year students in higher learning institutions. Numerous past studies have shown that students faced difficulties in comprehending and applying the programming concept when writing programs to solve problems. A slight negative experience at the initial stage of the studies is enough to disappoint the students. This then resulted in lowering the motivation of students to learn programming which impacted the students’ performance in the programming course. Thus, an approach must be developed so that the motivation to learn and practice programming remains high. This article proposes the use of Turtle Graphics at the initial stage of Java Programming course in Universiti Kebangsaan Malaysia. Via this approach, by writing suitable programs, the students are able to produce animations and graphics output. Students’ motivation levels are then measured via the ARCS model, which measure the students’ motivation based on four aspects, namely attention, relevance, confidence, and satisfaction. The results of this study found that the students demonstrate high motivation in all four motivational aspects.


I. INTRODUCTION
Specifically, computer programming is a fundamental element for a world that is currently facing the 4th Industrial Revolution (4IR). Computer programming is no longer limited to university students undertaking Computer Science courses, but everyone needs to have the ability to do programming [1], [2]. This situation resulted in the necessity to re-evaluate the approach towards teaching and learning in higher education.
Programming is the foundation for the Computer Science and Information Technology curriculum, and generally, for the STEM (Science, Technology, Engineering, and Mathematics) fields. Literature study reports almost everyone agreed that teaching and learning of programming, particularly, the first programming course usually known as CS1 is tough and challenging for the students [3]- [7] and Manuscript  failure rate is high [8]- [10]. Lecturers also found that it is quite challenging to teach the programming course [6], [11], [12]. This is supported by the finding of a study on the programming lab tests performance in comparison with the lab exercises, which showed that the average percentage of all correct answers (full marks) in the lab exercises was 69.8% compared to only 8.9% in the lab tests [13]. The CS1 programming course is an important foundation for other courses in the Computer Science field.
Many factors contribute to the challenges in the teaching and learning of programming courses. For instance, the features and concepts involved in the programming subject, do raise various problems [10]. The programming concept is difficult to comprehend, particularly by new students [4], [14]. This causes many students to admit that they dislike programming because they have to work hard to understand the concepts. The difficulties in understanding a programming concept are even more challenging for object-oriented programming languages [5], [14], [15]. The programming characteristic that builds one concept over another different concept also renders difficulties to the students at the initial phase, which led to the complication of moving to the next phase of learning. Besides the concepts, students also face difficulty in handling the complex syntax of the programming language [16]. They face challenges in converting the algorithm to a program using the correct syntax. Programming also requires the ability to think abstractly, make generalizations, and think critically [17]. A programmer must imagine and understand many abstract terms, which do not have any similarities with real-life. These and many other situational problems make CS1 a very challenging course both for lecturers and students in a higher learning institution. In addition, [17] succinctly compiled the problems into a) the teaching strategies that did not support the students' various styles of learning, b) a dynamic teaching concept that used static resource materials, c) lecturers focused more on teaching about the programming language instead of the method to solve teaching problems, d) students lack the motivation to learn programming, e) programming requires an abstract thinking capacity, f) students lack sufficient logical and mathematical knowledge, g) programming language has a complex syntax, h) students were introduced to programming at a difficult stage of their life.
The problems described inadvertently will impact upon the motivation of the students to learn programming, which will in turn has an impact on the students' performance in a programming course. A slight negative experience at the initial stage of learning is enough to discourage the students [4]. This will prove detrimental in the long run because, in order to succeed at programming, students need to put in a lot of effort in doing exercises, and students would not be able to go through them all unless they are highly motivated [18]. Thus, increasing or retaining students' motivation at certain levels are necessary in their learning process [19]. Therefore, an approach is needed to enhance the students' motivation in learning programming. This proposed approach will also have to consider the needs of the current generation that are now entering the institutions of higher learning. At the present time, the students are from the Z generation who are inclined towards the visual learning style [20]. For the visually inclined students, it is difficult to understand an abstract concept, more so with static resource material.
The following section will discuss the concept of learning motivation and the ARCS model which is used to measure motivation. Section III briefly reviews the graphical approaches used in the teaching of programming. Section IV outlines the research method. This is followed by sections V and VI which respectively describe the case study and the results obtained. Section VII presents the conclusion of the study and future works.

II. MOTIVATION TO LEARN
Reference [21] defines motivation as a process that energizes, directs, and sustains behavior. Motivation influences students' focus and effort in completing an activity or achieving a learning goal. Self-determination theory represents a framework for the study of motivation and individual personality that emphasizes internal resource for personality development, attitude and behavior [22]. There are two types of motivation related to self-determination theory, namely intrinsic and extrinsic motivation. Intrinsic motivation refers to the desire to perform something due to interest and self-satisfaction. On the other hand, extrinsic motivation is based on external goals, such as to gain certain rewards or to avoid punishment.
According to [22], intrinsic motivation can be enhanced when a student feels that he or she has competence, autonomy, and relatedness. Competent refers to someone who feels that he or she performed a task efficiently. The sense of competence can only be achieved if a person has the autonomy, that is when someone can control his or her action. Meanwhile, relatedness refers to a situation in which someone wishes to interact meaningfully with other people. Reference [23] classified extrinsic motivation into four categories, namely external regulation, introjected regulation, identified regulation, and integrated regulation. Extrinsic motivation with the lowest autonomy is in the external regulation in which it happens due to conformity to external needs, rewards, or punishment. Typically, an action is taken in a coerced or desperate situation. Extrinsic behavior with the most autonomy is in integrated regulation, which happened self-consciously.

A. ARCS Motivational Framework Model
ARCS is a motivational design model that was developed by Keller [24] to enhance and retain students' motivation to learning. Motivational framework refers to the layout process of the resources and procedure to improve the motivation for learning. The purpose is to increase students' participation in learning activities. ARCS model comprises four factors, namely attention, relevance, confidence, and satisfaction. 1) Attention: Related to learning activities that are essential to gain and sustain students' attention. To stimulate students' motivation to learn, the lecturer needs to get their attention at the initial learning process with something unexpected. This attention must be retained during the learning process using a different approach. 2) Relevance: It is important to ensure that the student believes that the learning experience meets their personal goals. Students should clearly understand that the learning activity is relevant to their needs to effect a positive attitude. 3) Confidence: The main reason for students to be less motivated is due to fear of failure or too much expectancy for success. The lecturer needs to design the learning activities so that the students believe that they can learn the content and will succeed in an assignment.
Confidence is imperative to ascertain success. 4) Satisfaction: For students to have desire to continue learning, they must be satisfied with the result or process of learning. Satisfaction can result from extrinsic and intrinsic factors. Extrinsic factors are external factors such as grades or material rewards. Intrinsic factors can be very powerful, such as feelings of accomplishments and feelings of competent. Students' satisfaction will sustain motivation in learning. These four components of motivation are based on a learning-related motivational theory that was introduced by Keller [24] in 1987. The ARCS model has been applied and validated in multiple research in various fields [25]- [29]. The ARCS model combined the theories of learning behavior, cognitive, and effective learning in a framework to measure motivation and learning achievement [26].
Keller [24] divided each of the four categories into three subcategories based on the motivation variables listed in the categories, as shown in Table I.

B. Related Works
Several previous studies employed the ARCS model in learning of programming. Initially, [30] used the ARCS model to measure the programming internal training motivation for the ICT industry in Japan. Next, [25] applied the ARCS model in testing the suitability of using the textual programming language (TPL) for primary school students. Later, [31] compared the application of textual programming language (TPL) and visual programming language (VPL) towards primary school students. The three studies employed a 12-item questionnaire based on the subcategories in Table I.
Reference [19] applied the ARCS model in programming learning at Qatar University by developing an e-learning module, including classroom interaction. He used a 5-item questionnaire to assess the approach's effectiveness.
Reference [26] used the ARCS model to measure students' motivation using blended learning for the Science Computer students at one of the universities in Saudi Arabia. They employed the Instructional Materials Motivational Survey (IMMS) questionnaire, which has 36 items that measured the four categories of the ARCS model.
Reference [32] integrated the ARCS model and problem-based learning (PBL) with a flipped classroom for learning of programming. They used a 21-item questionnaire based on the four categories of the ARCS model.

III. GRAPHICS LIBRARY APPROACH IN CS1
Most of the animation and graphics library approach used in learning programming is based on the LOGO programming language. LOGO was created by Seymour Papert and several fellow researchers at Massachusetts Institute of Technology (MIT) in 1967 [33]. LOGO is a language to teach children the basics of programming. The turtle in LOGO is a pointer object that can be operated and moved based on simple instructions. Lines are drawn following the turtle movement. When the LOGO language was first introduced, the instructions controlled a physical device in the shape of a turtle. With the development of the computer monitor technology, the turtle was depicted as a screen cursor as seen in the current computer. Among the instructions that can be given to the turtle are FORWARD n for moving n steps forward and RIGHT n for turning n degrees to the right.
The application of the graphics libraries in the teaching of programming in the universities has been reported several decades ago. Reference [34] applied the Karel the Robot libraries in the programming course. Karel the Robot was developed in 1981 for the introduction of the Structured Programming course, using Pascal. Karel the Robot continued development, and there are several popular versions, such as Robot [35] and Karel J Robot [36], which have been widely used in the teaching of the basic programming course.
Reference [37] developed the graphics libraries in ANSI C before converting it to Java. They encountered several problems while developing the libraries because the graphics library in the early version of Java was not stable. The Turtle package was developed by [33] using the Java language to be used in the CS1 course teaching. They employed the inverted curriculum approach, which was introduced by [38]. With the approach, the important concepts were introduced first, followed by the explanation later. The Turtle package was used in every topic of the course. A positive effect was reported, but no analysis was conducted to show the efficacy.
Reference [39] developed Traffic libraries using the Eiffel programming language. The Traffic libraries provide a large scale of interactive multimedia and graphics environment that allow the students to produce game programs in the basic programming course. The libraries which have nearly 150,000 lines of codes and 750 class allows the students to write programs to manipulate an application domain, which in this case is the traffic system of a city. Without using the libraries, it is impossible for the students to produce such programs in the basic programming course. They designed an introductory programming course based on the inverted curriculum approach in which students used the software libraries without the need to know the actual implementation of the libraries. This approach is based on the object-first approach, which was first introduced in the Computing Curricula 2001 document. With this approach, students can produce large programs, which are almost similar to the programs made by professionals, based on the capacity of the libraries.

IV. METHOD
This study proposed a new course structure for Computer Programming Course at the Faculty of Information Science and Technology (FTSM), Universiti Kebangsaan Malaysia (UKM), to replace the traditional approach. In the new course structure, Turtle Graphics approach that implements the object-first paradigm is applied in the development of new course materials to introduce the basic concept of programming.
The participants of this study consist of 167 students who enrolled for Computer Programming Course during 2017/2018 academic session. At the end of week four of the course, students' motivation is measured using the ARCS model. Variability: I am fascinated with the various problems that programming can solve using TurtleGraphics. Relevence

R1
Goal orientation: TurtleGraphics approach helps me to understand the basic concept of programming.

R2
Motive matching: TurtleGraphics is a suitable choice for me to learn a basic programming concept.

R3
Familiarity: I am familiar with the basic concept of programming that was introduced by TurtleGraphics.

Confidence C1
Learning requirement: I am clear about the purpose of using TurtleGraphics in the programming course. C2 Success opportunity: I can write a programme well using TurtleGraphics. C3 Personal Control: I am confident to write a programme to solve a problem using TurtleGraphics. Satisfaction S1 Natural consequences: Solving a programming assignment using TurtleGraphics give me satisfaction (e.g., in producing an artwork assignment). S2 Positive consequences: I am happy to be able to produce a good programme using TurtleGraphics. S3 Equity: I am satisfied with the assessment method of the TurtleGraphics programme that I produce. Motivation M Overall, using TurtleGraphics motivate me to learn programming.
The measuring instrument is adapted from the questionnaire that has been verified in the studies by Tsukamoto et al. [25], [30], [31], which is based on Keller's [24] 12 categories ARCS model. Table II shows the questionnaire that has been adapted and verified by an expert. The 13th item is to measure the overall level of motivation. The questionnaire is measured using 5-point Likert Scale (from 1=strongly disagree to 5=strongly agree).
The questionnaire reliability level analysis, with a Cronbach Alpha value of 0.973, indicates that the level of reliability of the questionnaire items is very good [40].

V. A CASE STUDY AT UNIVERSITI KEBANGSAAN MALAYSIA
In the Faculty of Information Science and Technology (FTSM), Universiti Kebangsaan Malaysia (UKM), the traditional approach has been used since the CS1 programming course was first introduced in the 1980s. Programming languages used in the 1980s and early 1990s were FORTRAN and Pascal using the structured programming approach. Around 1994, the programming language was changed to C language and later to C++ in the early 2000s. Even though the C++ language is an object-oriented language, the approach used is still the structured programming approach.
Computer Programming is a core course for all programmes of FTSM, namely Computer Science Programme, Information Technology Programme, and the Software Engineering Programme. It is compulsory for every student of FTSM to take the Computer Programming course during the first semester of their study, followed by two or more other programming courses in the following semester according to their chosen programme. The Computer Programming course is conducted through lectures, tutorials, and laboratory sessions. Students' performance is assessed through laboratory tests, which requires the students to solve problems with hands-on coding. The first-year students who enrolled in FTSM came from various backgrounds. About half of them have learned basic programming at the pre-university level, either in Matriculation Programmes, Foundation Programmes or in High Schools. The other half of the students do not have any formal knowledge of programming before entering FTSM.
The faculty management decided to use the Java language in 2015 as the CS1 programming language replacing the C/C++ language, which has been used since 1994. The management also stipulated the objects-first approach is used by introducing the object-oriented programming concept at the beginning of the course.
A holistic effort to design a new teaching module and approach for the Computer Programming course was conducted at the beginning of the first semester for the 2015/2016 academic session. A study was performed for similar courses in other universities, both locally and abroad, and followed by several discussion sessions with the faculty. Three main aspects were emphasized; first, the programming language to be used, second, the teaching methodology, and third, the content material and supporting technology [41].
For the first aspect, it imposed by the faculty that the programming language to be used is the Java language. Java language was chosen because it has several advantages compared to C/C++ used earlier. Java is widely used in universities [42], [43] and industries [44]. Besides, Java supported extensive class libraries, including the well-established graphics libraries that can be utilized to develop software libraries to allow students to write programs with animation and graphics output as early as the first laboratory session in the CS1 course.
The second aspect involved the selection of teaching methodology, whether applying the objects-first approach, or the structured approach. The objects-first approach was selected as Java is an object-oriented language. Furthermore, the introduction of objects-first approach was made easy by using the libraries developed, such as the turtle graphics libraries.
The third aspect involved identifying the content and the supporting technology. Research was conducted on several technologies and software libraries used by other institutions, such as the turtle graphics concept that was introduced by Seymour Papert in 1967 [33], Karel the Robot [34], Alice, BlueJ and Greenfoot environment. The approach selected for implementation in the first semester of the 2015-2016 academic session was to develop a turtle graphics library based on the turtle graphics concept. The changes made are summarized in Table III.  Table IV listed the topics for the proposed new course. Topic 1 is the Introduction to programming and Java which discussed the overview of programming and Java, and the history of Java. 9. Array & array processing (1-dimensional array) 8 10. String and string processing 9 11. Problem solving II 10 12. Static variables and methods 11 13. Array and array processing (2-dimensional array) 12 13. Array and array processing (2-dimensional array) 13 14. Classes 14 Revision Topic 2 introduced the basic concept of object-oriented. Firstly, a few examples of real-world objects are used to discuss the concept of state, behavior and identity of an object. This followed by a discussion on how objects are created and used in programs, and how to communicate with the objects. To facilitate students' understanding of writing object-oriented programs, the TurtleGraphics library is used. Topic 2 asserted that the objects-first approach is employed.
The example used in Topic 2 is to draw a square, which also introduces the concept of sequential structure (Fig. 1). In Topic 3, input statement and variables are introduced that enable students to write a program that can draw square of different sizes. Topic 4 and 5 introduced the concept of repetition structure and selection structure respectively. The example discussed in Topic 4 is to draw 10 squares in a row using for statement. The output is shown in Fig. 2. For the selection structure, the example shows a condition to check the odd or even number to determine the degree of angle that the turtle turns. The program segment with the output is shown in Fig. 3.
The teaching material was delivered as presentation slides during lectures. Follows, students are required to practice the learned concept and hands-on during the laboratory session. Students are required to write Java programs using the TurtleGraphics library to solve the given problems. On week 4, students' ability to use the Eclipse environment to write programs to solve problems using the TurtleGraphics library was evaluated through a laboratory test. Three simple problems are given and students need to complete them in two hours. Students' performance in the laboratory test is encouraging. The majority of students managed to solve the problems given in the test and 87.5% scored full marks as compared to only 48% of students obtained full marks in the earlier session, which used the traditional approach.
In order to gauge students' motivation and skill in using TurtleGraphics, they were asked to write a program that draws a creative artwork using the TurtleGraphics library as an assignment. They were given two weeks to submit their work. Fig. 4 shows some of the creative artwork returned.

VI. MOTIVATION ANALYSIS USING THE ARCS MODEL
Students' motivation towards programming using the TurtleGraphics approach was evaluated using the ARCS motivational model introduced by Keller [24]. The number of respondents for this study was 169 students who attended the Computer Programming course during semester 1, 2017/2018 session. Table V shows the result of this study.
The students' level of motivation toward using TurtleGraphics at the start of the programming course was measured using the 5-point Likert scale (1=strongly disagree, 2=disagree, 3=moderately agree, 4=agree, 5=strongly agree). A descriptive analysis of the min score reading using the indicators are divided into three levels, namely low (1.00 -2.33), medium (2.34 -3.66), and high (3.67 -5.00).   Table V in a bar chart form. Based on the mean score, all the respondents give a high response for all items. This indicates that the use of TurtleGraphics is effective to enhance students' motivation in learning programming. The highest item is A1 (4.4734), namely perception arousal, which indicates that the students enjoy using TurtleGraphics to learn programming. The lowest item is R3 (4.0769), namely familiarity, which means the students are less familiar with the programming basic concept. This is due to nearly half of students who took the course have never learned programming before entering university, and also due to some slow learners who found programming is difficult. Further analysis is based on four motivational elements that were outlined in the ARCS model, namely attention (A), relevance (R), confidence (C), and satisfaction (S), is presented in Table VI. The mean score is high for all the four motivational elements. The highest element is attention (A) at 4.3748, which shows that the TurtleGraphics approach in the programming course can attract the students' attention. The lowest element among the four elements is confidence (C) at 4.1696, which could be caused by several students who have never learned programming before, and the students who are weak in understanding the programming concept. These students might need a longer time to understand the required concepts. The mean average score for the overall motivational study is 4.2870, which shows that the TurtleGraphics approach in the basic programming course can retain the students' motivation effectively in learning programming.

VII. CONCLUSION
This paper articulates the results of a research that was done to develop an approach for the teaching and learning of programming at a local university in Malaysia. The main concerns when developing the approach was that, this approach must be able to help students to retain the level of motivation needed in learning programming and, it must also cater to the needs of the new generation of students entering the higher institutions of learning. The proposed approach is the graphics output approach using the TurtleGraphics library which formed part of the introductory CS1 course at FTSM, UKM. The purpose is to make sure that the students remain motivated by reducing students' frustration and anxiousness, particularly during the early stage of the programming course. The results indicate that students' motivation from the four aspects of the ARCS model was high, with the overall motivation value of 4.2870 (out of the maximum score of five). This indicates that the approach has the potential to be used in the teaching and learning of programming in other institutions of higher learning.
The authors are currently exploring the potential of using the graphics library approach by designing and developing suitable new graphics libraries to be applied on different topics in Computer Programming course. This will be discussed in another article. Another plan is to conduct the discussed approach to students of different levels such as pre-university and high school.
Marini Abu Bakar is a senior lecturer in the Faculty of Information Science and Technology, Universiti Kebangsaan Malaysia. Her research interests include programming education, computer graphics computing and software technology.
Muriati Mukhtar is an associate professor at the Faculty of Information Science and Technology, Universiti Kebangsaan Malaysia. Her research interests include e-service design and service science.
Fariza Khalid is a senior lecturer at the Faculty of Education, Universiti Kebangsaan Malaysia. Her research interests include e-learning, online communities of practice and emerging technologies for educational purposes.