Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 5511405

Browse files
authored
abs.js: abs_val() --> absVal() for standardjs (TheAlgorithms#144)
1 parent a90b487 commit 5511405

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

‎maths/abs.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
https://en.wikipedia.org/wiki/Absolute_value
1212
*/
1313

14-
function abs_val (num) {
14+
function absVal (num) {
1515
// Find absolute value of `num`.
1616
'use strict'
1717
if (num < 0) {
@@ -22,5 +22,5 @@ function abs_val (num) {
2222
}
2323

2424
// Run `abs` function to find absolute value of two numbers.
25-
console.log('The absolute value of -34 is ' + abs_val(-34))
26-
console.log('The absolute value of 34 is ' + abs_val(34))
25+
console.log('The absolute value of -34 is ' + absVal(-34))
26+
console.log('The absolute value of 34 is ' + absVal(34))

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /