Skip to content

Commit 3ab1fb2

Browse files
committed
change into original value of movieLength
1 parent 8211642 commit 3ab1fb2

1 file changed

Lines changed: 6 additions & 10 deletions

File tree

Lines changed: 6 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
const movieLength = 3000; // length of movie in seconds
1+
const movieLength = 8784; // length of movie in seconds
22

33
const remainingSeconds = movieLength % 60;
44
const totalMinutes = (movieLength - remainingSeconds) / 60;
@@ -9,21 +9,17 @@ const totalHours = (totalMinutes - remainingMinutes) / 60;
99
const result = `${totalHours}:${remainingMinutes}:${remainingSeconds}`;
1010
console.log(result);
1111

12-
13-
14-
1512
//A.There are six variable declararions
1613

1714
//B. no function calls
1815

19-
// C.The % represents a remainder. The operator returns the remainder leftover when one operand which in
20-
// this cas is movieLength is divided by a second operand in this case 60%.
21-
16+
//C.The % represents a remainder. The operator returns the remainder leftover when one operand which in
17+
// this cas is movieLength is divided by a second operand in this case 60%.
2218

2319
// D.it means it is changing the value that was in second into minute by dividing it 60 after the top calculation makes it whole number.
2420

2521
//E. It represents the duration of the movie.movieLength/movieDuration.
26-
22+
2723
// f) Try experimenting with different values of movieLength. Will this code work for all values of movieLength? Explain your answer
28-
29-
// yes it works, i experimented it with various values. I found it to be working properly.
24+
25+
// yes it works, i experimented it with various values. I found it to be working properly.

0 commit comments

Comments
 (0)