1
no this is illegal.
'boolean pos' is not a correct identifer.
2
var age;
var price;
if(age>=0&&age<=3){
price="Free";
}else
if(age>=4&&age<=12){
price=3.99;
}else
if(age>=13&&age<=65){
price=9.99;
}else if(age>65){
price=5.99;
}
3
var ch;
ch=prompt("enter a
character");
var res;
if(ch=='A'||ch=='a'){
res="Excellent";
}else if(ch=='B'||ch=='b'){
res="Good";
}else if(ch=='C'||ch=='c'){
res="Average";
}else if(ch=='D'||ch=='d'){
res="Need
Improvement";
}else if(ch=='E'||ch=='e'){
res="Poor";
}
4
for(var i=1;i<=1000;i++){
console.log(3*i);
}
5
for(var i=1;i<=100;i++){
console.log(Math.random()*2-1);
}
6
for(var i=1;i<=100;i++){
console.log(Math.floor(Math.random()*200)-100);
}
All answers are supposed to be in Java script thanks! 1. Is the following statement legal?...