Eto pa kasi binigay saamen ng prof namin
PROBLEM MAKES PERFECT
// create a program to determine if the age is qualified to Vote.
function age(){
var age = 18;
if (age >= 18) { document.write("QUALIFIED TO VOTE");}
else{ document.write("NOT QUALIFIED"); }
}
// create a program to determine if the number is odd or even
function oddeven(){
var num = 19;
if (num%2== 0) { document.write("EVEN");}
else{ document.write("ODD"); }
}
// create a program to determine if the number is positive, negative or zero
// --
// --
// --
// create a program to find a maximum between two numbers
//--
//--
//--
//--
//create a program to determine if the character is alphabet, number or special
function char(){
var myChar = "3";
if (myChar >='a' && myChar <='z') {
document.write(myChar+" is Alphabet");
// create a program to determine if the alphabet is consonant or vowel
}
else if (myChar >=0 && myChar <=9){
document.write(myChar+" is number");
}
else{document.write("Special Characters"); }
}
//Create a program that will compute the Average Grade of two subject and determine if passed or failed
function average(){
var subject1 = 50;
var subject2 = 90;
var ans = (subject1 + subject2)/2;
if (ans >= 75 ) {
document.write("PASSED");
}
else{
document.write("FAILED");
}
}
PRAKTISS PO TAU!! Goodluck !!