Saturday, September 4, 2021

Student Grade Solver in AngularJS

 Machine Problem

Write a program that will ask user to give the student name, subject, prelim grade, midterm grade, and end term grade. The program will display the student name, subject and compute the final grade of the student in the particular subject.

I am currently accepting programming work, IT projects, school and application development, programming projects, thesis and capstone projects, IT consulting work, computer tutorials, and web development work kindly contact me at the following email address for further details.  If you want to advertise on my website kindly contact me also in my email address also. Thank you.

My email address is the following jakerpomperada@gmail.com, jakerpomperada@aol.com, and jakerpomperada@yahoo.com.

My mobile number here in the Philippines is 09173084360.

My telephone number at home here in Bacolod City, Negros Occidental Philippines is  +63 (034) 4335675.

Here in Bacolod City I also accepting computer repair, networking, and Arduino Project development at a very affordable price. My website is www.jakerpomperada.blogspot.com and www.jakerpomperada.com

If you like this video please click the LIKE button, SHARE, and SUBSCRIBE to my channel.

Your support on my channel is highly appreciated.

Thank you very much.





Program Listing

<!-- index.htm

  Author   : Prof. Jake Rodriguez Pomperada, MAED-IT, MIT

  Date     : July 24, 2021  Saturday 2:14 PM

  Place    : Bacolod City, Negros Occidental

  Websites : www.jakerpomperada.com and www.jakerpomperada.blogspot.com

  Email    : jakerpomperada@gmail.com

 -->

<html>

  <head>

    <title>Student Grade Solver in AngularJS</title>

  <script type="text/javascript" src="angular.min.js"></script>

     <script>

    var myApp=angular.module("myModule",[]);

    myApp.controller("Compute_Grade",function($scope) {

    $scope.SolveGrade=function()

    {

           

         compute_grade =  ($scope.prelim * 0.20) +  

                           ($scope.midterm * 0.30) +

                           ($scope.endterm * 0.50);


        $scope.title="===== Student Grade Report =====";

         $scope.student = "Student Name  : " + $scope.student_name;

         $scope.subject = "Subject       : " + $scope.subject_name; 

         $scope.final_grade =   "Final Grade   : " + compute_grade.toFixed(0);

       }



    });

     </script>

     

 </head>

 <style>

body {

font-family: arial;

font-size: 25px;

font-weight: bold;

}

</style>

 <body ng-app="myModule" ng-controller="Compute_Grade">

  <h3>Student Grade Solver in AngularJS</h3>

 <div>

  <table border="0">

  <tr>

  <td>

  Enter Student Name  </td>

       <td>

        &nbsp;&nbsp;&nbsp;&nbsp;

         <input type="text"  size="40" ng-model="student_name" required/>

       </td>

      <tr>

  <td>

  Enter Subject Name </td>

       <td>

        &nbsp;&nbsp;&nbsp;&nbsp;

         <input type="text" size="40" ng-model="subject_name" 

         required/>

       </td>   

       </tr>

       <tr>

         <td>&nbsp;&nbsp;&nbsp;</td>

        </tr>

       <tr>

       <td>

      Enter Prelim Grade </td>

       <td>

        &nbsp;&nbsp;&nbsp;&nbsp;

         <input type="number" ng-model="prelim"/>

       </td>   

       </tr>

       <tr>

       <td>

      Enter Midterm Grade </td>

       <td>

        &nbsp;&nbsp;&nbsp;&nbsp;

         <input type="number" ng-model="midterm"/>

       </td>   

       </tr>

       <tr>

       <td>

      Enter Endterm Grade </td>

       <td>

        &nbsp;&nbsp;&nbsp;&nbsp;

         <input type="number" ng-model="endterm"/>

       </td>   

       </tr>

       <tr>

         <td>&nbsp;&nbsp;&nbsp;</td>

        </tr>

      <tr>

      <td colspan="5">

      <input type="button" ng-click="SolveGrade()"

          title="Click here to solve the student grade."

      value="Solve Student Grade"/>

      </td>

      </tr>

      </table>

      <br>

       {{ title }} <br><br>

       {{ student | uppercase }} <br>

       {{ subject | uppercase }} <br><br>

       {{ final_grade }} 

     </div><br>

       </div>

    </body>

</html>

No comments:

Post a Comment