# Using online tool CodingBat when solving programming exercises

## Details

##### Title:

##### Type:

##### Original Languages:

##### Annotations:

The CAWI type has been selected due to poor fit of the remaining categories.

The students were given programming tasks to solve in the self-learning tool CodingBat. There was also the possibility to get help from the tool if necessary.

The CodingBat tasks, which served as an instrument, were as follows:

1.) Given n of 1 or more, return the factorial of n, which is n * (n-1) * (n-2) … 1. Compute the result recursively (without loops).

2.) The fibonacci sequence is a famous bit of mathematics, and it happens to have a recursive definition. The first two values in the sequence are 0 and 1 (essentially 2 base cases). Each subsequent value is the sum of the previous two values, so the whole sequence is: 0, 1, 1, 2, 3, 5, 8, 13, 21 and so on. Define a recursive fibonacci(n) method that returns the nth fibonacci number, with n=0 representing the start of the sequence.

The original tasks are available online:

1) Faculty of n: https://codingbat.com/prob/p154669

2) Fibonacci sequence: https://codingbat.com/prob/p120015

## Documents related to the Instrument

Type | Description | Document Language | File |
---|---|---|---|

Other | Screenshot of the CodingBat exercise on the faculty of n (source: Parlante, Nick (2022). Recursion 1 - factorial. URL: https://codingbat.com/prob/p154669). | English | codingbat.PNG |