Skip to content

Commit 466f652

Browse files
committed
Add console log for last4Digits
1 parent c4049e2 commit 466f652

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

  • Sprint-2/2-mandatory-errors

‎Sprint-2/2-mandatory-errors/3.js‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,4 +11,6 @@ const last4Digits = cardNumber.slice(-4);
1111

1212
//Solution
1313
//Prediction - The code would not run because 'cardNumber' is declared as numbers instead of a string.
14-
// The '.slice()' method belongs to strings and arrays, it could only work by treating it's subject as a sequence of characters.
14+
// The '.slice()' method belongs to strings and arrays, it could only work by treating it's subject as a sequence of characters.
15+
16+
console.log(last4Digits);

0 commit comments

Comments
 (0)