We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 9b3eb4b commit 41d76e2Copy full SHA for 41d76e2
Sprint-2/3-mandatory-implement/3-to-pounds.js
@@ -24,3 +24,10 @@ const convertToUpperSnakeCase = (str) =>
24
str.toUpperCase().trim().split(" ").join("_");
25
26
console.log(convertToUpperSnakeCase("hello there")); // "HELLO_THERE"
27
+
28
+// Four functions are implemented because each one performs a specific task.
29
+// This makes the code easier to read, reuse, and maintain.
30
+//
31
+// The penceToPounds function was updated to handle a pence string like "399p".
32
+// It removes the "p", converts the value to a number, and divides by 100
33
+// so the function correctly returns "£3.99".s
0 commit comments