A Two-Systems Perspective for Computational Thinking
11 This is a pre-print of the following paper: Arvind W. Kiwelekar, Swanand Navandar and DharmendraK Yadav,
A Two systems Perspective for Computational Thinking, accepted version for 12th InternationalConference on Intelligent Human Interaction (IHCI 2020) held from 24th to 26th November 2020 at Exco-Daegu South Korea.
Cite this chapter as:
Arvind W Kiwelekar, Swanand Navandar, and Dharmendar K Yadav,
A Twosystems Perspective for Computational Thinking , in the proceedings of 12th International Conference onIntelligent Human Interaction (IHCI 2020) Exco-Daegu South Korea November 2020 Publisher: Springer.1 a r X i v : . [ c s . C L ] D ec Two-Systems Perspective for Computational Thinking
Arvind W Kiwelekar , Swanand Navandar , Dharmendra K. Yadav December 8, 2020
Abstract
Computational Thinking (CT) has emerged as one of the vital thinking skills in recent times, especiallyfor Science, Technology, Engineering and Management (STEM) graduates. Educators are in search ofunderlying cognitive models against which CT can be analyzed and evaluated. This paper suggestsadopting Kahneman’s two-systems model as a framework to understand computational thought process.Kahneman’s two-systems model postulates that human thinking happens at two levels, i.e. fast and slowthinking. This paper illustrates through examples that CT activities can be represented and analyzedusing Kahneman’s two-systems model. The potential benefits of adopting Kahneman’s two-systemsperspective are that it helps us to fix the biases that cause errors in our reasoning. Further, it alsoprovides a set of heuristics to speed up reasoning activities.
Keywords:
Cognitive Modelling Computational Thinking Problem Solving.
Computational Thinking is emerging as a generic skill for everyone, whether someone is a Computer Pro-grammer, Data Scientist, Biologist, Physician, Lawyer, or an ordinary human being. The pioneers whocoined CT [18] often equate it to general skills like reading, writing, and speaking to highlight the broaderapplicability of CT. Because CT being the most relevant skill to learn, educators have been designing spe-cialized curricula [9] to impart this skill from the kindergarten level. Also, educators [6] are differentiatingthe
CT for Beginners from the
CT for Professionals so that it can be applied by working professionals toaddress their domain-specific problems.In its simplest sense, Computational Thinking is a specialized type of human thinking required to solveproblems through computers. CT being a human thought process, it gets influenced by human psychologicaltraits such as attention, memory, impressions, feelings, opinions, biases and heuristics. This paper highlightsthe necessity of a rich framework grounded in Psychological theories to analyze the influences of these traitson CT.Hence this position paper suggests adopting one such theory i.e. Kahneman’s two-systems model ofthinking, from the field of Psychology, to analyze the human aspects involved in computational thinking.The article defines Computational Thinking and elements of Kahneman’s two systems model of thinking inSection 2, 3, and 4. Section 5 identifies CT activities and map them on Kahneman’s two systems model ofthinking. Section 6 relates our proposal with the existing applications of Kahneman’s model of thinking inComputer Science. The paper concludes with directions for future work. ∗ Department of Computer Engineering,Dr Babasaheb Ambedkar Technological UniversityLonere-Raigad 402103 India { awk,snavandar } @dbatu.ac.in Department of Computer Engineering,Motilal Nehru National Institute of Technology, AllahabadPrayagraj - 211004, [email protected]
In the seminal paper on
Computational Thinking , J M Wing [18] clearly explains the breadth of the CTas a thought process. This broad definition of CT includes a set of skills such as solving a problem usingcomputers, designing and evaluating a complex system, and understanding human behaviour.For computer programmers, CT is a way of representing a real-life problem and solving it with the help ofcomputers. For example, writing a program to find an optimal path to travel from a source to a destination.For software engineers, CT refers to designing and evaluating a complex information processing systemsuch as an online railway or an airline reservation system.For computer scientists, CT refers to getting insights about human behaviour by answering questionssuch as (i) what are the limitations and power of computation? , (ii) what does it mean by intelligence? , (iii) what motivates us as a human being to perform or not to perform a specific action? .This broad coverage of topics included under computational thinking highlights that computationalthinking is beyond mere computer programming or coding.Further, Aho [1] brings out the differences between the terms
Computation and
Computational Thinking .He recommends that the term
Computation shall be restricted to denote those tasks for which the semanticscan be described through a formal mathematical model of computation(e.g., Finite Automata, Pi-Calculus,Turing Machine). The tasks for which no such appropriate models exist, it is necessary to invent such formalmodels.Computational thinking being a complex thought process, the paper proposes to analyze it throughthe cognitive model of thinking propagated by Psychologist, Economist, and Nobel Laureate Prof. DanielKahneman. Though the Kahneman’s model of thinking is not a formal model useful to describe exactsemantics of CT activities, the cognitive model helps us to fix the errors in our reasoning and to sharpenour thought process.
The human cognitive processes, such as judgement and decision making, are complex and intricate. Tounderstand these processes in a better and simplified way, many psychologists have proposed that humanthinking operates at two different levels [7]. First one is a fast, intuitive, and effortless way of thinkingrequiring less or no attention. The second one is a slow, intentional, and effortful way of thinking, oftenrequiring forceful attention or focus. The theories accepting this separation are also known as dual-system ordual-process theories of human cognition. In this paper, this model is referred as a Kahneman’s two-systemsmodel of thinking because non-psychologists [14, 11, 15]] have started using it to understand the cognitiveprocesses involved in their domains after the publication of the book titled
Thinking, Fast and Slow [10].Kahneman’s model primarily consists of two systems, as shown in Figure 1. These systems are labelledas
System 1 and
System 2 . These systems can be considered as mental constructs or fictitious agents drivingthe thought process. The
System 1 usually responds to routine operations quickly in an unconscious waywhile
System 2 is called in action in a novel situation, responds consciously and slowly. In comparison with3able 1: Program 1 and Program 2Program 1 Program 2i n t main ( ) { i n t x=10 , y =20;i n t temp = x ;x = y ;y = temp ;p r i n t f ( ” x= %d , y= %d ” , x , y ) ;r e t u r n 0 ; } i n t main ( ) { i n t x = 1 0 , y = 2 0 ;x = x + y ;y = x − y ;x = x − y ;p r i n t f ( ” x= %d , y= %d ” , x , y ) ;r e t u r n 0 ; } System 2 , the
System 1 is more error-prone and unreliable. The following examples illustrate the existenceof such two different modes of thinking in the context of Basic Algebra.
Example 1
We answer the question without any effort, quickly, and accurately. But, to answer the question
17 X 24 =? , we require to put effort and do deliberate calculations.
Example 2
Consider the following example from Kahneman’s book [10] page 44:A bat and ball cost $ ¢ using their intuitive thinking ( System 1 ) which is a wronganswer, while the correct answer is 5 ¢ .This example is purposefully designed to demonstrate that System 1 is error-prone.
Example 3
Let us consider the third example. This is a question asked in the end-semester examinations of Firstcourse on Computer Programming (C Programming) offered at Dr. B. A. Tech. University India to itsundergraduate students of Engineering.
Question:
Which of the program(s) shown in Table 1 swaps the values of the variables x and y ?(A) Program 1(B) Program 2(C) None of the programs Program 1 or Program 2.(D) Both Program 1 and Program 2.While answering this question, majority of the students (77%) out of the eighty three students enrolled forthe course have answered it as ( A ) i.e. Program 1 while the correct answer is ( D ) i.e. Both Program 1 andProgram 2. This example demonstrates that, most of the students relied on their System 1 while answeringthe question. 4
Characteristics of Dual System Thinking
The examples in the previous section demonstrate that thinking happens in two different modes. To elaboratethe working further, we describe some of the characteristics crucial for understanding computational thinking.This section describes these characteristics in a general setting. However, these characteristics also apply inthe context of computational thinking in its broader sense when we presume human as a computing agent.1.
Both systems work concurrently
The
System 1 and
System 2 work concurrently and cooperatemost of the times while thinking and reasoning about the external world. When conflict arises,
System2 attempts to regulate
System 1 . The
System 1 generates feelings, impressions, and inclinations. Whenasked by
System 1 , the
System 2 endorses and transforms them into beliefs and attitudes. Neithersystem can be turned off but
System 2 is lazy to respond as compared to
System 1 .2.
The two-systems model represents a division of labour
The
System 1 performs some tasksefficiently while others are performed by
System 2 . The
System 1 performs tasks such as: (i) Toexecute skilled responses after imparting proper training. For example, applying brakes while driving.(ii) Recognizing typical situations, recognizing norms and standards and complying to conventions. Forinstance, recognizing irritations in the voice of a known person. (iii) To identify causes and intentions.For example, identifying reasons behind delayed arrival of an aircraft.The
System 2 is called in action when a task requires more effort and attention, such as filling a formto apply for graduate studies or selecting a University for graduate studies.3.
Biases and heuristics guide the
System 1 responses
The responses of
System 1 are quick anderror-prone. They are quick because heuristics drives them and they are error-prone because biasesguide them. For example, we often quickly judge the level of confidence of a person through the externalattributes such as being well-dressed and well-groomed, which is an instance of the use of a heuristiccalled halo effect . For example, the Example 3 from the previous section, students who respondedwith the wrong option ( A ), they relied on a bias called availability bias . The availability bias selects afamiliar and widely exposed option over the least exposed and un-familiar one. The option ( A ) fulfillsthis criteria and majority of the students select it.These characteristics play a significant role in understanding human thought process in general and compu-tational thinking in our case. We often consider computational thinking is a deliberate thought process driven by the goals to be achieved.So it is a slow and effortful activity requiring a high level of focus and attention. Hence, we may concludethat computational thinking is a domain of
System 2 , and there is no or minimal role to play for
System 1 .In this section, we hypothesize that two systems govern computational thinking. First one is fast, automaticand intuitional. The second one is slow, effortful, and systematic.To support our argument, we identify smaller and primitive computational thinking activities and mapthem on
System 1 and
System 2 . Table 2 shows some of the computational thinking activities mapped to
System 1 and
System 2 .While defining this mapping, we assumed a minimum level of knowledge and skills that students acquireafter the courses on Computer Programming, Data Structures and Algorithm, Software Engineering, andTheory of Computation. This requirement is typically satisfied by the students studying in the final year ofComputer Science and Engineering programs offered at Indian Universities.The mapping in the Table 2 is based on random analyses of students’ responses to the questions askedfrom different examinations of courses on Computer Programming, Data Structures and Algorithms, SoftwareEngineering, and Theory of Computation.However, the mapping can be validated by conducting intentional examinations to observe studentsresponse time and other physiological parameters such as dilation of pupil, blood pressure and heart rate.5able 2: Computational Thinking Activities
System 1 System 2
1. Deciding upon primitive data types for vari-ables.2. Separating user-defined identifiers from lan-guage defined one.3. Identifying input and outputs of a givenfunction or Application Programming Inter-face.4. Separating comments from code segment.5. Performing simple operations like push , pop , f ront , and rear on a given data structuresuch as stack and queue .6. Finding the root and leaf nodes of a givenbinary tree.7. Categorizing machine learning problem asa linear regression, classification or logisticregression, or a clustering problem from agiven scatter plot. 1. Decomposing a large program into smallerreusable programs.2. Deciding upon a data structure (e.g., Stack,Queue, Tree, Graph) to realize the solutionfor a given problem.3. Performing tree or graph traversals (e.g.,Pre-order, Post-order, Breadth-First, andDepth-First).4. Deciding upon when to use a data-driven orMachine Learning approach and an algorith-mic approach.5. Separating concerns such as business logicfrom communication, coordination andother such concerns.6. Answering the question: how difficult is it tosolve a give problem through computer? orperforming complexity analysis.7. Recognizing the situations where approxi-mate solution may be sufficient.8. Code inspection for compliance and vio-lation of programming guidelines such asnames of classes in Object Oriented pro-grams shall be noun and the name of amethod shall be verb.Researchers from Psychology found that when someone is engaged in System 2 thinking activities, heart rateincreases, blood pressure raises, and eye pupils dilate.The list in Table 2 is a suggestive and not comprehensive one which can be extended by including activitiesfrom Software Design, Project Management and other higher-level cognitive activities. Many Computer Science Researchers have started taking an interest in dual-system theory from the field ofPsychology and applying it in various ways. This section briefly reviews some of the recent approaches toplace our approach in the proper context. These approaches can be broadly classified into three categories.1.
To decompose information processing systems
These approaches assume that information pro-cessing is a complex activity which can be decomposed into two parts. The first one that requiresfast responses with an acceptable level of accuracy and the second one is requiring slow but correctreasoning. A complex information task is then divided into these lines.For example, Di Chen et al. [4], develop a two-systems approach to solve Sudoku puzzles and the6rystal Structure Phase mapping problem. They use deep neural networks to design
System 1 , whichperforms the tasks of pattern recognition and heuristic evaluation. The responsibility of constraintreasoning is delegated to
System 2 which adopts Integer programming and Monte Carlo Tree Searchtechniques for this purpose.In another example, Sudeep Mittal et al. [12] adopt a similar two-systems approach to representknowledge and reasoning. They use the structure called Vector Space, as a fast-thinking processor,to recognize patterns. Further, they use the structure called Knowledge Graph, as a slow thinkingprocessor to reason about complex dependency relations.Some of the other similar approaches include decomposing the optimization problem at a global levelin Smart Grid system [8] and to build ethical AI applications [16].2.
To analyze the role of Biases in Software Engineering
The Kahneman’s model of thinking isa rich framework for cognitive analysis, and it has been found useful to investigate human aspectsof various software engineering and project management activities. Some of these studies, [13, 17, 2,3, 19], have analyzed the effect of cognitive biases and heuristics on software engineering and projectmanagement activities.3.
To analyze cognitive activities
The researchers have been using the two-systems model of thinkingto explain the higher-level cognitive tasks. For example, Maria Csernoch [5] use Kahneman’s model tovalidate the observations in the study conducted to analyze errors in Computer Problem Solving bynon-professionals. In the Second example, Udo Kannengiesser et al. [11] analyze the process of designthinking to decompose it into smaller activities and map the lower activities as fast and slow thinkingactivities.The work presented in this paper breaks down the high-level Computational Thinking task to smaller ac-tivities and map them on two systems as done by Udo Kannengiesser et al. [11] for the task of designthinking.
The paper identifies the necessity of investigating the psychological dimension of Computational Thinkingskill. Further, it proposes to adopt Kahneman’s Two-systems model of thinking for this purpose becauseit is simple to utilise, and it is rich enough in terms of analytical tools. Primarily, it separates the humanthought process in two broad categories: (i) Fast and intuitional activities, and (ii) Slow and deliberate one.The paper illustrates the applicability of the approach by mapping CT activities on two systems requiringfast and slow thinking as a baseline for further empirical investigation. The identified mapping needs to besubstantiated by carrying out either controlled experiments or through the detailed analyses of students’responses in an educational setting.Kahneman’s two-systems model is rich as a cognitive analysis framework providing a broad set of biasesand heuristics, which can be used to study the human aspects of computational thinking. It will be interestingto explore the role of these biases and heuristics in the context of Computational Thinking to make it lesserror-prone and a faster reasoning activity.
Acknowledgement
The first author would like to acknowledge his younger brother Mr. Nagesh Kiwelekar for inspiring him toexplore the connections between dual system theories and Computer Science.
References [1] Alfred V Aho. Computation and computational thinking.
The Computer Journal , 55(7):832–835, 2012.72] Sara Behimehr and Hamid R Jamali. Cognitive biases and their effects on information behaviour ofgraduate students in their research projects.
Journal of Information Science Theory and Practice ,8(2):18–31, 2020.[3] G¨ul C¸ alıklı and Ay¸se Ba¸sar Bener. Influence of confirmation biases of developers on software quality:an empirical study.
Software Quality Journal , 21(2):377–416, 2013.[4] Di Chen, Yiwei Bai, Wenting Zhao, Sebastian Ament, John M Gregoire, and Carla P Gomes. Deepreasoning networks: Thinking fast and slow, for pattern de-mixing. 2019.[5] Maria Csernoch. Thinking fast and slow in computer problem solving.
Journal of Software Engineeringand Applications , 10(1):11–40, 2017.[6] Peter J Denning and Matti Tedre.
Computational thinking . MIT Press, 2019.[7] Jonathan St BT Evans and Keith E Stanovich. Dual-process theories of higher cognition: Advancingthe debate.
Perspectives on psychological science , 8(3):223–241, 2013.[8] Gautam Goel, Niangjun Chen, and Adam Wierman. Thinking fast and slow: Optimization decomposi-tion across timescales. In , pages1291–1298. IEEE, 2017.[9] Sridhar Iyer. Teaching-learning of computational thinking in k-12 schools in india.
ComputationalThinking Education , page 363, 2019.[10] Daniel Kahneman.
Thinking, fast and slow . Macmillan, 2011.[11] Udo Kannengiesser and John S Gero. Design thinking, fast and slow: A framework for kahneman’sdual-system theory in design.
Design Science , 5, 2019.[12] Sudip Mittal, Anupam Joshi, and Tim Finin. Thinking, fast and slow: Combining vector spaces andknowledge graphs. arXiv preprint arXiv:1708.03310 , 2017.[13] Rahul Mohanani, Iflaah Salman, Burak Turhan, Pilar Rodr´ıguez, and Paul Ralph. Cognitive biases insoftware engineering: a systematic mapping study.
IEEE Transactions on Software Engineering , 2018.[14] Charles W Murdock and Barry Sullivan. What kahneman means for lawyers: Some reflections onthinking, fast and slow.
Loy. U. Chi. LJ , 44:1377, 2012.[15] Anne Preisz. Fast and slow thinking; and the problem of conflating clinical reasoning and ethicaldeliberation in acute decision-making.
Journal of paediatrics and child health , 55(6):621–624, 2019.[16] Francesca Rossi and Andrea Loreggia. Preferences and ethical priorities: Thinking fast and slow in ai.In
Proceedings of the 18th International Conference on Autonomous Agents and MultiAgent Systems ,pages 3–4, 2019.[17] Andreas R¨uping. Taming the biases: a few patterns on successful decision-making. In
Proceedings ofthe 19th European Conference on Pattern Languages of Programs , pages 1–5, 2014.[18] Jeannette M Wing. Computational thinking.
Communications of the ACM , 49(3):33–35, 2006.[19] Andrzej Zalewski, Klara Borowa, and Damian Kowalski. On cognitive biases in requirements elicitation.In