From f4edb9aa73958a932c0ecc6ce28a16776f48efaf Mon Sep 17 00:00:00 2001 From: Katrina Owen Date: Tue, 18 Apr 2023 09:10:49 +0200 Subject: [PATCH 1/2] Sync simple-linked-list docs with problem-specifications The simple-linked-list exercise has been overhauled as part of a project to make practice exercises more consistent and friendly. For more context, please see the discussion in the forum, as well as the pull request that updated the exercise in the problem-specifications repository: - https://forum.exercism.org/t/new-project-making-practice-exercises-more-consistent-and-human-across-exercism/3943 --- exercises/practice/simple-linked-list/.docs/instructions.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/exercises/practice/simple-linked-list/.docs/instructions.md b/exercises/practice/simple-linked-list/.docs/instructions.md index 9ec958d4..4d845fac 100644 --- a/exercises/practice/simple-linked-list/.docs/instructions.md +++ b/exercises/practice/simple-linked-list/.docs/instructions.md @@ -10,6 +10,6 @@ Each element in the list contains data and a "next" field pointing to the next e This variant of linked lists is often used to represent sequences or push-down stacks (also called a LIFO stack; Last In, First Out). -As a first take, lets create a singly linked list to contain integers, and provide functions to reverse a linked list. +As a first take, lets create a singly linked list to contain the range (1..10), and provide functions to reverse a linked list and convert to and from arrays. When implementing this in a language with built-in linked lists, implement your own abstract data type. From ef0c844048adc3815c20e82d19dc3543a2d561cd Mon Sep 17 00:00:00 2001 From: Katrina Owen Date: Tue, 18 Apr 2023 09:27:41 +0200 Subject: [PATCH 2/2] Sync simple-linked-list docs with problem-specifications The simple-linked-list exercise has been overhauled as part of a project to make practice exercises more consistent and friendly. For more context, please see the discussion in the forum, as well as the pull request that updated the exercise in the problem-specifications repository: - https://forum.exercism.org/t/new-project-making-practice-exercises-more-consistent-and-human-across-exercism/3943 --- .../simple-linked-list/.docs/instructions.md | 20 +++++++++++-------- .../simple-linked-list/.docs/introduction.md | 5 +++++ 2 files changed, 17 insertions(+), 8 deletions(-) create mode 100644 exercises/practice/simple-linked-list/.docs/introduction.md diff --git a/exercises/practice/simple-linked-list/.docs/instructions.md b/exercises/practice/simple-linked-list/.docs/instructions.md index 4d845fac..04640b1f 100644 --- a/exercises/practice/simple-linked-list/.docs/instructions.md +++ b/exercises/practice/simple-linked-list/.docs/instructions.md @@ -1,15 +1,19 @@ # Instructions -Write a simple linked list implementation that uses Elements and a List. +Write a prototype of the music player application. -The linked list is a fundamental data structure in computer science, often used in the implementation of other data structures. -They're pervasive in functional programming languages, such as Clojure, Erlang, or Haskell, but far less common in imperative languages such as Ruby or Python. +For the prototype, each song will simply be represented by a number. +Given a range of numbers (the song IDs), create a singly linked list. + +Given a singly linked list, you should be able to reverse the list to play the songs in the opposite order. -The simplest kind of linked list is a singly linked list. -Each element in the list contains data and a "next" field pointing to the next element in the list of elements. +~~~~exercism/note +The linked list is a fundamental data structure in computer science, often used in the implementation of other data structures. -This variant of linked lists is often used to represent sequences or push-down stacks (also called a LIFO stack; Last In, First Out). +The simplest kind of linked list is a **singly** linked list. +That means that each element (or "node") contains data, along with something that points to the next node in the list. -As a first take, lets create a singly linked list to contain the range (1..10), and provide functions to reverse a linked list and convert to and from arrays. +If you want to dig deeper into linked lists, check out [this article][intro-linked-list] that explains it using nice drawings. -When implementing this in a language with built-in linked lists, implement your own abstract data type. +[intro-linked-list]: https://medium.com/basecs/whats-a-linked-list-anyway-part-1-d8b7e6508b9d +~~~~ diff --git a/exercises/practice/simple-linked-list/.docs/introduction.md b/exercises/practice/simple-linked-list/.docs/introduction.md new file mode 100644 index 00000000..0e1df72f --- /dev/null +++ b/exercises/practice/simple-linked-list/.docs/introduction.md @@ -0,0 +1,5 @@ +# Introduction + +You work for a music streaming company. + +You've been tasked with creating a playlist feature for your music player application.