first thing first i would like to say thank you so much for dropping by. I'm a beginner at Javascript. And now dealing with some issue, and i need help to identify what is wrong with my lines. So here it is, i want to find out the highest number from the variable using conditional statement inside a function, I'm stuck right now.
EDITED : Thankyou guys for helping me out, now I have a clear vision about what I should learn more.
const number1 = 103;
const number2 = 72;
const number3 = 189;
const getMax = (a, b, c) => {
let max = a;
if(b > max) {
let max = b;
} else if (c > max){
let max = c;
};
return max;
}
getMax(number1, number2, number3);
console.log(`Max number is ${getMax}`);```