<input type="radio" id="m">M
<input type="radio" id="w">M
<button id="go">GO</button>
document.getElementById("go").onclick = go;
let m = document.getElementById("m").checked;
let w = document.getElementById("w").checked;
function go (){
let massege = m == true ? "hello Man" : w == true ? "hello Wooman": "who are you;
alert(massage);
}
Подскажите, что я не правильно делаю? Если в input radio поставлю галочку, оно ведь будет true
?
id = "radioMaleM"
иid = "radioMaleW"
?