Skip to content

Commit 1bf5f21

Browse files
Merge pull request #7 from anasmak04/master
add another problems
2 parents 712eafa + 2f0fe6f commit 1bf5f21

File tree

3 files changed

+16
-1
lines changed

3 files changed

+16
-1
lines changed

README.md

+4-1
Original file line numberDiff line numberDiff line change
@@ -45,5 +45,8 @@
4545
| Problem - 41 | [Find month name. ](https://github.com/anasmak04/Problem-solving-with-JavaScript/blob/master/problem-41.js) |
4646
| Problem - 42 | [Multiplication table. ](https://github.com/anasmak04/Problem-solving-with-JavaScript/blob/master/problem-42.js) |
4747
| Problem - 43 | [ Fibonacci ](https://github.com/anasmak04/Problem-solving-with-JavaScript/blob/master/problem-43.js) |
48+
| Problem - 44 | [ swap ](https://github.com/anasmak04/Problem-solving-with-JavaScript/blob/master/problem-44.js) |
49+
| Problem - 45 | [ max two numbers ](https://github.com/anasmak04/Problem-solving-with-JavaScript/blob/master/problem-45.js) |
4850

49-
<!-- | Problem - 44 | | -->
51+
52+
<!-- | Problem - 46 | | -->

problem-44.js

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
let a = 1;
2+
let b = 2;
3+
let c = a;
4+
a = b
5+
b = c
6+
console.log(a,b)

problem-45.js

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
function maxN (a,b){
2+
return a > b ? `max numbers : ${a}` : `max numbers : ${b}`
3+
}
4+
5+
const result = maxN(-1,4); //// OUTPUT SHOULD BE A
6+
console.log(result)

0 commit comments

Comments
 (0)