Tuesday, April 12, 2022

Odd and Even Numbers Using Functions and Arrays in C++

 A simple program asks the user to give a series of numbers and then the program will display the odd and even numbers using functions and arrays using a C++ programming language.

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 in 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.

Please subscribe to my channel  https://www.youtube.com/channel/UCOs-lpOoIeJoh6gpJthPoGg


=================================================

Want to support my channel?


GCash Account


Jake Pomperada

09173084360


Paypal

https://paypal.me/jakerpomperada


Patreon

https://www.patreon.com/jakerpomperada

 

Thank you very much for your support





Program Listing

// Written By: Mr. Jake R. Pomperada, MAED-IT
// Date : November 21, 2010 Sunday
// Tool : C++


#include <iostream>

using namespace std;

// Global Variables

int a=0,r=0,data=0,b=0;
int values[10];


void get_data();
void display_even();
void display_odd();


void get_data(void)
{
     cout << "\n\n";
cout << "\tOdd and Even Numbers Using Functions and Arrays in C++";
     cout << "\n\n";
     cout << "How Many Numbers : ";
     cin >> data;
     cout << "\n";
        for (b=1; b <= data; b++)
            {
            cout << "Enter Item No. "
                  << b <<  " :";
            cin >> b[values];
          }
}


void display_even(void)
{

    cout << "\n\n";
    cout << "List of Even Numbers : ";
    cout << "\n\n";
        for (a=1; a<=data; a++) {
            r = a[values] % 2;
            if (r ==0) {
                cout << " " <<a[values]
                << " ";
         }

     }
}


void display_odd(void)
 {
    cout << "\n\n";
    cout << "List of Odd Numbers : ";
      cout << "\n\n";
     for (a=1; a<=data; a++) {
         r = a[values] % 2;
         if (r !=0) {
          cout << " " <<a[values]
            << " ";
         }
     }
 }
 main() {

     get_data();
     display_even();
     display_odd();
     cout << "\n\n";
     system("pause");
 }


Monday, April 11, 2022

Quotient of Two Numbers Using ng-bind in AngularJS

Quotient of Two Numbers Using ng-bind in AngularJS

 Machine Problem

Write a program that uses the ng-bind directive that will accept two numbers, and then the program will compute the quotient of the two numbers, and display the results on the screen.

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 in 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.

Please subscribe to my channel  https://www.youtube.com/channel/UCOs-lpOoIeJoh6gpJthPoGg


=================================================

Want to support my channel?


GCash Account


Jake Pomperada

09173084360


Paypal

https://paypal.me/jakerpomperada


Patreon

https://www.patreon.com/jakerpomperada

 

Thank you very much for your support




Program Listing

<!-- index.htm

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

  Date     : October 11, 2021   Monday  2:50 PM

  Place    : Bacolod City, Negros Occidental

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

  Email    : jakerpomperada@gmail.com

 -->

<html>

<head>

  <title>Quotient of Two Numbers Using ng-bind in AngularJS</title>

</head>

<style>

body {

  font-family: arial;

  font-size: 25px;

  font-weight: bold;

}

</style>

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

</script>


<script>

       var app = angular.module("quotient", []);

        app.controller('app', ['$scope', function ($app) {

         $app.divide= function () {

                $app.solve = 0;

                $app.solve = ($app.val_1 / $app.val_2);

                $app.display = $app.solve + ".";

            }

        }]);

    </script> 

</script>  

<div ng-app="quotient" ng-controller="app">

  <form>

  <table border="0" cellspacing=10>

  <tr>Quotient of Two Numbers Using ng-bind in AngularJS</tr>

  <tr>

  <td>Enter First Value </td>

  <td><input type="number"  ng-model="val_1" ng-change="divide()"></td>

  </tr>

   <tr>

  <td>Enter Second Value </td>

  <td><input type="number"  ng-model="val_2" ng-change="divide()"></td>

  </tr>

   <tr>

  </table>

  </form>

  <span>The quotient of {{val_1}}, and {{val_2}} is </span> 

    <span ng-bind="display"></span>

   </p> 

</div>

</body>

</html>


Sunday, April 10, 2022

Grade Checker With Remarks in C++

Grade Checker With Remarks in C++

 A simple program to check if the given grade is passed or failed using C++ programming language.

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 in 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.

Please subscribe to my channel  https://www.youtube.com/channel/UCOs-lpOoIeJoh6gpJthPoGg


=================================================

Want to support my channel?


GCash Account


Jake Pomperada

09173084360


Paypal

https://paypal.me/jakerpomperada


Patreon

https://www.patreon.com/jakerpomperada

 



 Program Listing

#include <iostream>

using namespace std;

int main()
{
    char subject[50];
    string remarks;
    int grade=0;

  cout << "\n\tGrade Checker With Remarks in C++\n\n";
  cout <<"\tEnter Subject    : ";
  cin.getline(subject, 50);
  cout <<"\tEnter Your Grade : ";
  cin >> grade;
 
    if (grade>=75) {
        remarks = "PASSED";
    } else {
        remarks = "FAILED";
    }


  cout <<"\n\n";
  cout << "\t======= DISPLAY RESULT ======\n\n";
  cout <<"\tSubject  : " << subject <<"\n";
  cout <<"\tRemarks  : " << remarks;
  cout <<"\n\n";

}

Addition of Three Numbers Using Functions in PHP

Addition of Three Numbers Using Functions in PHP

 A simple program to show how to create a function to compute the sum of three numbers using PHP programming language.

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 in 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.

Please subscribe to my channel  https://www.youtube.com/channel/UCOs-lpOoIeJoh6gpJthPoGg


=================================================

Want to support my channel?


GCash Account


Jake Pomperada

09173084360


Paypal

https://paypal.me/jakerpomperada


Patreon

https://www.patreon.com/jakerpomperada




Program Listing

index.php

<?php

//creating a addition function in PHP
function addition($a,$b,$c)
{
$sum=$a+$b+$c;
echo "The sum of $a, $b and $c is $sum.";
}

echo "<br> Addition of Three Numbers Using Functions in PHP<br><br>";

//calling the addtion function

addition(1,2,3);

?>


Addition of Two Numbers in Go

Addition of Two Numbers in Go

 Machine Problem

Write a program that will ask the user to give two numbers and then the program will compute the sum of the two numbers and display the results on the screen

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 in 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.

Please subscribe to my channel  https://www.youtube.com/channel/UCOs-lpOoIeJoh6gpJthPoGg


=================================================

Want to support my channel?


GCash Account


Jake Pomperada

09173084360


Paypal

https://paypal.me/jakerpomperada


Patreon

https://www.patreon.com/jakerpomperada





 Program Listing

/* addition.go
   Author   : Mr. Jake Rodriguez Pomperada,MAED-IT, MIT
   Date     :  March 20, 2021 Saturday  10:12 PM
   Location : Bacolod City, Negros Occidental
   Websites :www.jakerpomperada.comandwww.jakerpomperada.blogspot.com
   Emails   : jakerpomperada@gmail.com and jake_pomperada@tup.edu.ph
 */

package main

import "fmt"

func main() {
var val1 int32
var val2 int32
var sum int32

fmt.Print("\n")
fmt.Print("\tAddition of Two Numbers in Go")
fmt.Print("\n\n")
fmt.Print("\tEnter two numbers: ")
fmt.Scanf("%d%d",&val1,&val2)
sum = (val1+val2)
fmt.Print("\n")
fmt.Println("\tThe sum of",val1, "and",val2 ,"is",sum,".")
fmt.Print("\n")
fmt.Print("\tEnd of Program")
fmt.Print("\n")
}


 

Saturday, April 9, 2022

Average Grade Solver in JavaScript

Average Solver in JavaScript

 A simple program to solve the average grade of the student in a class using JavaScript programming language.

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 in 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.

Please subscribe to my channel  https://www.youtube.com/channel/UCOs-lpOoIeJoh6gpJthPoGg


=================================================

Want to support my channel?


GCash Account


Jake Pomperada

09173084360


Paypal

https://paypal.me/jakerpomperada


Patreon

https://www.patreon.com/jakerpomperada




Program Listing


index.htm


<!DOCTYPE html>

<html lang="en">

<head>

    <meta charset="UTF-8">

    <meta http-equiv="X-UA-Compatible" content="IE=edge">

    <meta name="viewport" content="width=device-width, initial-scale=1.0">

    <title>Average Grade Solver</title>

    <style>

        * {

            box-sizing: border-box;

            margin: 0;

            padding: 0;

        }

        body {

            min-height: 100vh;

            display: flex;

            justify-content: center;

            align-items: center;

            background-color: #AAAF99;

            color: #000;

            font-family: sans-serif;

        }

        main {

            padding: 50px;

            border-radius: 10px;

            background-color: #fff;

            min-width: 500px;

        }

        h1 {

            margin-bottom: 5px;

            font-size: 28px;

            text-align: center;

        }

        h2 {

            margin-bottom: 30px;

            font-size: 20px;

            text-align: center;

        }

        .block {

            margin: 0 auto 12px;

            display: flex;

            align-items: center;


        }

        label {

            display: block;

            width: 35%;

            line-height: 40px;

            background-color: #2F4C58;

            color: #eee;

            text-align: center;

        }

        input {

            padding: 10px;

            width: 65%;

            font-size: 14px;

            border-radius: 0 5px 5px 0;

            border: 2px solid #000;

            outline: none;

        }

        .btnBlock {

            display: flex;

            width: 100%;

        }

        .btn {

            display: inline-block;

            padding: 15px;

            background-color: #63A583;

            color: #fff;

            outline: none; 

            border: none;

            cursor: pointer;

            width: 150px;

            width: 50%;

            font-size: 16px;

            text-decoration: none;

            text-align: center;

            transition: all .2s;

        }

        .btnReset {

            background-color: #6E93D6;

        }

        .btn:hover {

            opacity: 0.9;

        }

        .average {

            display: block;

            width: 100%;

            margin-top: 12px;

            padding: 20px 0;

            background-color: #2F4C58;

            font-size: 16px;

            text-align:center;

            color: #f3f3f3;

        }

        .hide {

            display: none;

        }

    </style>

</head>

<body>

    <main class="container">

        <h1>AVERAGE GRADE SOLVER</h1>

        <h2>Jake R. Pomperada, MAED-IT, MIT</h2>

        <form action="" id="frmCalc">

            <div class="block">

                <label for="grade1">Prelim Grade:</label>

                <input type="number" min="1" max="100" id="grade1" autofocus required>

            </div>

            <div class="block">

                <label for="grade2">Midterm Grade:</label>

                <input type="number" min="1" max="100" id="grade2" required>

            </div>

            <div class="block">

                <label for="grade3">Final Grade:</label>

                <input type="number" min="1" max="100" id="grade3" required>

            </div>

            <div class="btnBlock">

                <button type="submit" class="btn">SUBMIT</button>

                <a href="" class="btn btnReset">RESET</a>

            </div>

            <div class="average hide"></div>

        </form>

    </main>


    <script>

        document.querySelector('#frmCalc').onsubmit  = (e) => {

            e.preventDefault()

            let ave = document.querySelector('.average'),

                arr = document.querySelectorAll(`[id*="grade"]`),

                total = 0;

            for(var i=0; i<arr.length; i++) total+= parseInt(arr[i].value)

            total = total/3

            ave.classList.remove('hide')

            ave.innerHTML = 'Your Average Grade is: '+total.toFixed(2)

        }

    </script>

</body>

</html>