Please note, this is a STATIC archive of website www.tutorialspoint.com from 11 May 2019, cach3.com does not collect or store any user information, there is no "phishing" involved.
Tutorialspoint

2H (33) Laetisha Wee RCG P2

<!DOCTYPE html>
<html>
<title>Web Page Design</title>
<head>
<script>

   document.write("=== Report Card ===<br>");
   document.write("Name:"+"Mary Lim <br>");
   document.write("Class:"+"2A <br>");
   document.write("Index No.:"+"27<br>"+"<br>");

   document.write("=== Grades ===<br>");
   document.write("English:"+"85"+"/100"+"(A)<br>");
   document.write("Mother Tongue :"+"72"+"/100"+"(B)<br>");
   document.write("Science :"+"69"+"/100"+"(C)<br>");
   document.write("Maths :"+"82"+"/100"+"(D)<br>");
   

   var urname = prompt ("Enter your name :");
   var urclass = prompt ("Enter your class :<br>");
   var urindex = prompt ("Enter your index :<br>");
   
   var urengmark = prompt ("Enter your English Marks :");
   var urmtmrk = prompt ("Enter your Mother Tongue Marks :<br>");
   var urscimrk = prompt ("Enter your Science Marks :<br>");
   var urmathmrk = prompt ("Enter your Math Marks :<br>");
   
      document.write("=== Report Card ===<br>");
   document.write("Name:"+ urname " <br>");
   document.write("Class:"+urclass "<br>");
   document.write("Index No.:"+urindex"<br>");

   document.write("=== Grades ===<br>");
   document.write("English:"+urengmark+"/100"+"(A)<br>");
   document.write("Mother Tongue :"+urmtmrk+"/100"+"(B)<br>");
   document.write("Science :"+ urscimrk+"/100"+"(C)<br>");
   document.write("Maths :"+urmathmrk +"/100"+"(D)<br>");
   


</script>
</head>
<body>
</body>
</html>

Online Javascript Editor

<!DOCTYPE html>
<html>
<title>Web Page Design</title>
<head>
<script>
function sayHello() {
   document.write("bye, Coding Ground!");
}
sayHello();
</script>
</head>
<body>
</body>
</html>

hiuu

<html>
   <head>
      <title>JavaScript String blink() Method</title>
   </head>
   
   <body>
   
      <script type = "text/javascript">
         var str = new String("Hello world");
         alert(str.blink());
      </script>
      
   </body>
</html>

2T Valerie Lee RCG Part 3

<!DOCTYPE html>
<html>
<title>Web Page Design</title>
<head>
<script>
var urname = prompt("Enter your name:");
var urclass = prompt("Enter your class");
var urindex = prompt("Enter your index number");

var urengmrk = prompt("Enter your English marks:");
var urmtmrk = prompt("Enter your Mother Tongue marks:");
var urscimrk = prompt("Enter your Science marks:");
var urmathmrk = prompt("Enter your Mathematics marks:");
var urtotalmrk = Number(urengmrk) + Number(urmtmrk) + Number(urscimrk) + Number(urmathmrk)

document.write("===Report Card=== <br>");
document.write("Name: " + urname + "<br>")
document.write("Class: " + urclass + "<br>")
document.write("Index No.: " + urindex + "<br>")
document.write("<br>")
document.write("===Grades=== <br>")
document.write("English: " + urengmrk + "/100 " + "(A) <br>")
document.write("Mathematics: " + urmathmrk + "/100 " + "(A) <br>")
document.write("Mother Tongue: " + urmtmrk + "/100 " + "(A) <br>")
document.write("Science: " + urscimrk + "/100 " + "(A) <br>")
document.write("Total marks: " + urtotalmrk + "/400" + "<br>")
</script>
</head>
<body>
</body>
</html>

2T 3 Report Card Generator Part 3

<!DOCTYPE html>
<html>
<title>Web Page Design</title>
<head>
<script>
function sayHello() {
   document.write("Hello, Coding Ground!");
}
sayHello();
</script>
</head>
<body>
</body>
</html>

2T 13 Liaw Ann Lin RCG Part 3

<!DOCTYPE html>
<html>
<title>Web Page Design</title>
<head>
<script>

 var yourname = prompt("What is your name?");
 var yourclass = prompt ("What is your class?");
 var indexno = prompt ("What is your index number?");
 var eng = prompt("What are your marks for english?");
 var mt = prompt("What are your marks for your Mother Tongue?");
 var math = prompt("What are marks for Math?"); 
 var science = prompt("What are your marks for Science?"); 
 var total = Number(eng) + Number(mt) + Number(math) + Number(science) 

     document.write("{ Report Card } <br>");
     document.write("Name: " + yourname + "<br>");
     document.write("Class: " + yourclass + "<br>");
     document.write("Index No.: " + indexno + "<br>");
     document.write("<br>");
     document.write(" { Grades } <br>");
     document.write(" English: " + eng + "/100" + " (A) <br>" );
     document.write("Mother Tongue: " + mt + "/100" + " (A) <br>");
     document.write("Math: " + math + "/100" + " (A) <br>");
     document.write("Science: " + science + "/100" + " (A) <br>");
     document.write("Total Marks: " + total + "/400" + "<br>")

</script>
</head>
<body>
</body>
</html>

Weather Checking Program

<!DOCTYPE html>
<html>
<title>Web Page Design</title>
<head>
<script>

//task 4A
document.write("Check weather today: <br>");
var weather = prompt ("Is the weather cloudy? ");
if(weather == "Yes"){
    document.write("Bring umbrella. ");
}
else{
    document.write("Go out and play! ");
}
document.write("<br><br>");

//task 4B.1
document.write("Check weather today: <br>");
var weather = prompt ("Is the weather cloudy? ");
weather = weather.toUpperCase();
if(weather == "YES"){
    document.write("Bring umbrella. ");
}
else {
    document.write("Go out and play! ");
}
document.write("<br><br>");

//task 4B.2
document.write("Check weather today: <br>");
var weather = prompt ("What is the weather today? Use 'a' for cloudy, 'b' for sunny and 'c' for rainy");
if(weather == "a") {
    document.write("The weather today is cloudy. Bring an umbrella. ");
}
else if (weather == "b") {
    document.write("The weather today is sunny. Go out and play! ");
}
else {
    document.write("The weather today is rainy. Stay at home. ")
}
document.write("<br><br>");



</script>
</head>
<body>
</body>
</html>

model ans (weather checking program)

<!DOCTYPE html>
<html>
<title>Web Page Design</title>
<head>
<script>
document.write("task 3B: <br>”)
var weather1 = prompt("What’s the weather like? Enter (A) for Rainy and (B) for Sunny.”)
weather1 = weather1.toUpperCase();
if (weather1 == "A") {
document.write("The weather today is rainy. Bring an umbrella.”);
}
else if(weather1 == "B") {
document.write("The weather today is sunny. Bring an umbrella.”);
}
else {document.write("You have keyed in the wrong input.”)
}

</script>
</head>
<body>
</body>
</html>

2T Isabelle (12) RCG Part 3

<!DOCTYPE html>
<html>
<title>Web Page Design</title>
<head>
<script>



</script>
</head>
<body>
</body>
</html>

Report Card Generator 3 Rhea 2T 17

<!DOCTYPE html>
<html>
<title>Web Page Design</title>
<head>
<script>

var name = prompt('Enter your name.');
var urclass = prompt('What is your class?');
var index = prompt('What is your index number?');

var eng = prompt('What are your english marks? (out of 100)?');
var math = prompt('What are your math marks? (out of 100)?');
var ursci = prompt('What are your science marks? (out of 100)?');
var urmt = prompt('What are your mothertongue marks? (out of 100)?');

var enggrade = '';
var mathgrade = '';
var urscigrade = '';
var urmtgrade = '';

if (eng >= 70){
    enggrade = ' (A)';
}

else if (eng >= 50){
    enggrade = ' (B)'
}

else{
    enggrade = ' (C)'
}

if (math >= 70){
    mathgrade = ' (A)';
}

else if (math >= 50){
    mathgrade = ' (B)'
}

else{
    mathgrade = ' (C)'
}

if (ursci >= 70){
    urscigrade = ' (A)';
}

else if (ursci >= 50){
    urscigrade = ' (B)'
}

else{
    urscigrade = ' (C)'
}

if (urmt >= 70){
    urmtgrade = ' (A)';
}

else if (urmt >= 50){
    urmtgrade = ' (B)'
}

else{
    urmtgrade = ' (C)'
}

document.write('===report card==='+'<br>');
document.write('Name:'+ ' '+ name + '<br>');
document.write('Class:'+ ' '+ urclass +'<br>');
document.write('Index No.:'+ ' ' + index + '<br>');

document.write('===grades==='+'<br>');
document.write('english:'+ ' '+ eng + '/100'+ enggrade + '<br>');
document.write('math:'+ ' '+ math + '/100'+ mathgrade +'<br>');
document.write('science:'+ ' '+ ursci + '/100'+ urscigrade + '<br>');
document.write('mothertongue:'+ ' '+ urmt + '/100'+ urmtgrade + '<br>');

document.write('===total score==='+'<br>')
var total = Number(eng) + Number(math) + Number(ursci) + Number(urmt)
document.write('your total score (out of 400) is:' + ' ' + total)



</script>
</head>
<body>
</body>
</html>

Previous 1 ... 4 5 6 7 8 9 10 ... 264 Next
Advertisements
Loading...

We use cookies to provide and improve our services. By using our site, you consent to our Cookies Policy.