Sunday, May 31, 2020

Remove Vowels in Java

I wrote this program to ask the user to give string and then the program to remove the vowels in the given string using Java programming language.

I am currently accepting programming work inventory system, enrollment system, accounting system, payroll system, information system, website design and development using WordPress, 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. My telephone number at home here in Bacolod City, Negros Occidental Philippines is +63 (034) 4335675.


Here in Bacolod City, Negros Occidental I also accepting computer repair, web development using WordPress, Computer Networking, and Arduino Project development at a very affordable price. My personal website is http://www.jakerpomperada.com


My programming website is http://www.jakerpomperada.blogspot.comI am also a book author you can purchase my books on computer programming and information technology in the following links below. https://www.unlimitedbooksph.com/

Program Listing

// demo.java
// Written By: Jake Rodriguez Pomperada
// Barangay Alijis, Bacolod City, Negros Occidental Philippines.
// www.jakerpomperada.com
// jakerpomperada@gmail.com
// May 14, 2020  Thursday

package test;

import java.util.Scanner;

public class demo {

   static String Remove_Vowels(String str)
   {
    return  str.replaceAll("[AIEOUaieou]","" );
   }
public static void main(String[] args) {
     
Scanner input = new Scanner(System.in);
     
     String str_given,display_result;
     
    System.out.print("\n\n");
    System.out.print("\tRemove Vowels in Java");
    System.out.print("\n\n");
    System.out.print("\tGive a String : ");
    str_given = input.nextLine();
    
    System.out.print("\n"); 
    System.out.print("\tString : " + str_given);
    display_result = Remove_Vowels(str_given);
    System.out.print("\n");
    System.out.print("\tResult : " + display_result);
    System.out.println();  
}

}

Remove Consonants in Java

I wrote this program to ask the user to give string and then the program to remove the consonants in the given string using Java programming language.

I am currently accepting programming work inventory system, enrollment system, accounting system, payroll system, information system, website design and development using WordPress, 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. My telephone number at home here in Bacolod City, Negros Occidental Philippines is +63 (034) 4335675.


Here in Bacolod City, Negros Occidental I also accepting computer repair, web development using WordPress, Computer Networking, and Arduino Project development at a very affordable price. My personal website is http://www.jakerpomperada.com


My programming website is http://www.jakerpomperada.blogspot.comI am also a book author you can purchase my books on computer programming and information technology in the following links below. https://www.unlimitedbooksph.com/

Program Listing

// demo.java
// Written By: Jake Rodriguez Pomperada
// Barangay Alijis, Bacolod City, Negros Occidental Philippines.
// www.jakerpomperada.com
// jakerpomperada@gmail.com
// May 14, 2020  Thursday

package test;

import java.util.Scanner;

public class demo {

   static String Remove_Consonants(String str)
   {
    return  str.replaceAll("[BCDFGHJKLMNPQRSTVXZbcdfghjklmnpqrstvxz]","" );
   }
public static void main(String[] args) {
     
Scanner in = new Scanner(System.in);
     
     String str_given,display_result;
     
    System.out.print("\n\n");
    System.out.print("\tRemove Consonants in Java");
    System.out.print("\n\n");
    System.out.print("\tGive a String : ");
    str_given = in.nextLine();
    
    System.out.print("\n"); 
    System.out.print("\tString : " + str_given);
    display_result = Remove_Consonants(str_given);
    System.out.print("\n");
    System.out.print("\tResult : " + display_result);
    System.out.println();  
}

}

Friday, May 29, 2020

ISANG CERTIFIED NA SEAMANLOLOKO. PANUORIN!

Shell Sort Using C++ STL

Here is a shell sort program was written by my good friend Tom from the United Kingdom using C++ STL. Thank you Tom for sharing your code to us.

I am currently accepting programming work inventory system, enrollment system, accounting system, payroll system, information system, website design and development using WordPress, 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. My telephone number at home here in Bacolod City, Negros Occidental Philippines is +63 (034) 4335675.

Here in Bacolod City, Negros Occidental I also accepting computer repair, web development using WordPress, Computer Networking, and Arduino Project development at a very affordable price. My personal website is http://www.jakerpomperada.com

My programming website is http://www.jakerpomperada.blogspot.comI am also a book author you can purchase my books on computer programming and information technology in the following links below.
https://www.unlimitedbooksph.com/


Program Listing

#include <iostream>
#include <vector>
#include <algorithm>
#include <iterator>

using namespace std;

enum class SortOrder
{
   Ascending,
   Descending
};

// based on https://gist.github.com/svdamani/dc57e4d1b00342d4507d
template <class Iter>
inline void selection_sort(Iter first, Iter last, SortOrder order)
{
   while (first != last)
   {
     if (order == SortOrder::Ascending)
       std::iter_swap(first, std::min_element(first, last));
     else
       std::iter_swap(first, std::max_element(first, last));

   ++first;
   }
}

int main()
{
   cout << "Original vector of Numbers\n";
   vector<int> v = { 2, 1, 5, 10, 3 };
   copy(begin(v), end(v), ostream_iterator<int>(cout, " "));

   cout << "\n\nVector sorted in ascending order:\n";
   selection_sort(begin(v), end(v), SortOrder::Ascending);
   copy(begin(v), end(v), ostream_iterator<int>(cout, " "));

   cout << "\n\nVector sorted in descending order:\n";
   selection_sort(begin(v), end(v), SortOrder::Descending);

   copy(begin(v), end(v), ostream_iterator<int>(cout, " "));

   cout << "\n\n";
   system("PAUSE");
}



Selection Sort in C++ Using STL

I wrote this selection sort program using C++ STL I hope you will find my work useful.

I am currently accepting programming work inventory system, enrollment system, accounting system, payroll system, information system, website design and development using WordPress, 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. My telephone number at home here in Bacolod City, Negros Occidental Philippines is +63 (034) 4335675.

Here in Bacolod City, Negros Occidental I also accepting computer repair, web development using WordPress, Computer Networking, and Arduino Project development at a very affordable price. My personal website is http://www.jakerpomperada.com

My programming website is http://www.jakerpomperada.blogspot.comI am also a book author you can purchase my books on computer programming and information technology in the following links below.
https://www.unlimitedbooksph.com/


Program Listing

#include <iostream>
#include <vector>
#include <algorithm>
#include <iterator>

using namespace std;

template<class T>
void SelSort(vector<T> & v, size_t start, size_t stop)
{
   size_t begin = start;
   size_t smallsofar = begin;
   if (start < stop)
   {
     for (size_t i = begin + 1; i <= stop; i++)
     {
       if (v[i] < v[smallsofar])
         smallsofar = i;
     }
     swap(v[begin], v[smallsofar]);
     SelSort(v, start + 1, stop);
   }
}

template<class T>
void SelSort(vector<T> & v)
{
   if(!v.empty())
     SelSort(v, 0, v.size() - 1);
}

int main()
{
   cout << "\t\t\t SELECTION SORT IN C++";
   cout << "\n\t\t Created By: Mr. Jake R. Pomperada, MAED-IT";
   cout << "\n\n";

   cout << "\n\t Original Arrangement of Numbers";
   cout << "\n\n";

   vector<int> v = { 2, 1, 5, 10, 3 };
   copy(begin(v), end(v), ostream_iterator<int>(cout, " "));

   SelSort(v);

   cout << "\n";
   cout << "\n\t Sorted Arragmenent of Number";
   cout << "\n\n";

   copy(begin(v), end(v), ostream_iterator<int>(cout, " "));

   cout << "\n\n";
   system("PAUSE");
}

Thursday, May 28, 2020

Wowowin: Paano naging Kapuso si Kuya Wil?

Francis Leo Marcos|News Update Gen.Guillermo Eleazar nag salita na?

Reverse the given String in Perl

I wrote this program using Perl programming language to ask the user to give a string and then the program will reverse the given string by the user.

I am currently accepting programming work inventory system, enrollment system, accounting system, payroll system, information system, website design and development using WordPress, 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. My telephone number at home here in Bacolod City, Negros Occidental Philippines is +63 (034) 4335675.

Here in Bacolod City, Negros Occidental I also accepting computer repair, web development using WordPress, Computer Networking, and Arduino Project development at a very affordable price. My personal website is http://www.jakerpomperada.com

My programming website is http://www.jakerpomperada.blogspot.comI am also a book author you can purchase my books on computer programming and information technology in the following links below.
https://www.unlimitedbooksph.com/


Program Listing

# reverse_string.pl
# Author   : Jake R. Pomperada,MAED-IT,MIT
# Date     : April 9, 2020   Wednesday 5:56 AM
# Location : Bacolod City, Negros Occidental
# Email    : jakerpomperada@gmail.com
# Website  : http://www.jakerpomperada.com

  

    print("\n");
    print("\tReverse the given String in Perl");
    print("\n\n");
    print("\tEnter a String : ");
    chomp($str=<STDIN>);

    $string =  ucfirst($str);
    $reverse_word = reverse($string);

    print("\n");
    print("\tString given          : $str");
    print("\n\n");
    print ("\tReverse Word         : $reverse_word\n"); 
    print("\n\n");
    print("\t\tEnd of Program");
    print("\n\n");

Tuesday, May 26, 2020

Ordinal Numbers in PHP

A simple program that I wrote to demonstrate ordinal numbers using PHP programming language.

I am currently accepting programming work inventory system, enrollment system, accounting system, payroll system, information system, website design and development using WordPress, 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. My telephone number at home here in Bacolod City, Negros Occidental Philippines is +63 (034) 4335675.

Here in Bacolod City, Negros Occidental I also accepting computer repair, web development using WordPress, Computer Networking, and Arduino Project development at a very affordable price. My personal website is http://www.jakerpomperada.com

My programming website is http://www.jakerpomperada.blogspot.comI am also a book author you can purchase my books on computer programming and information technology in the following links below.
https://www.unlimitedbooksph.com/



Sample Program Output


Program Listing

index.php


<html>
  <head>
    <title>Ordinal Numbers in PHP </title>
  </head>
  <style type="text/css">
    body {
      font-family: arial;
      size: 15px;
    }
  </style>
 <body>
  <h2> Ordinal Numbers in PHP </h2>
<?php

  function OrdinalNumberSuffix($num) {
    if (!in_array(($num % 100),array(11,12,13))){
      switch ($num % 10) {
        // Handle 1st, 2nd, 3rd
        case 1:  return $num.'st';
        case 2:  return $num.'nd';
        case 3:  return $num.'rd';
      }
    }
    return $num.'th';
  }


for ($i = 1; $i <= 255; $i++){
  echo OrdinalNumberSuffix($i) . "\t";
  if ($i % 10 == 0) {
    echo "\n";
  }
}

?>
</body>
</html>

Ordinal Numbers Using Pascal

   As I learned computer programming my first programming language that I have learned is Pascal the compiler that I am using during those days in college in Turbo Pascal 5.0. In this program I would like to reminisce the past by writing a program using Pascal as my programming language to accept a number from the user and then convert the number into ordinal equivalent values. In this sample program I am using Turbo Pascal 5.5 that is widely available right now to download free from any charges over the Internet. This problem I encounter during my college days in our programming class.

I am currently accepting programming work inventory system, enrollment system, accounting system, payroll system, information system, website design and development using WordPress, 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. My telephone number at home here in Bacolod City, Negros Occidental Philippines is +63 (034) 4335675.

Here in Bacolod City, Negros Occidental I also accepting computer repair, web development using WordPress, Computer Networking, and Arduino Project development at a very affordable price. My personal website is http://www.jakerpomperada.com

My programming website is http://www.jakerpomperada.blogspot.comI am also a book author you can purchase my books on computer programming and information technology in the following links below.
https://www.unlimitedbooksph.com/


Program Listing

    
    (* Ordinal_Numbers.pas*)
    (* Written By Mr. Jake R. Pomperada, MAED-IT *)
    (* Tools : Turbo Pascal 5.5. For DOS *)
    (* Date : November 24, 2015 *)
    Program Ordinal_Numbers;
    Uses Crt;
    Var number : integer;
    message : string;
    a: integer;
    mod100 : integer;
    mod10: integer;
    begin
    a:=0; mod10:=0; mod100:=0;
    clrscr;
    textcolor(yellow);
    write('Ordinal Number Generator in Pascal');
    writeln; writeln; writeln;
    write('Enter a Number : ');
    readln(number);
    writeln; writeln;
    for a:= 1 To number Do
    Begin
    mod10 := (a mod 10);
    mod100 := (a mod 100);
    if (mod10 = 1) AND (mod100 <> 11) then
    Begin
    message := 'st';
    End
    else if (mod10 = 2) AND (mod100 <> 12) then
    Begin
    message := 'nd';
    End
    else if (mod10 = 1) AND (mod100 <> 11) then
    Begin
    message := 'rd';
    End
    else
    Begin
    message := 'th';
    End;
    write(' ',a,message,' ');
    End;
    writeln; writeln;
    write('End of Program');
    readln;
    End.

Running Sum of Numbers Using Ordinal Indicators in C++

I wrote this simple program to demonstrate how to write a running sum of number using ordinal numbers in C++ programming language.

I am currently accepting programming work inventory system, enrollment system, accounting system, payroll system, information system, website design and development using WordPress, 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. My telephone number at home here in Bacolod City, Negros Occidental Philippines is +63 (034) 4335675.

Here in Bacolod City, Negros Occidental I also accepting computer repair, web development using WordPress, Computer Networking, and Arduino Project development at a very affordable price. My personal website is http://www.jakerpomperada.com

My programming website is http://www.jakerpomperada.blogspot.comI am also a book author you can purchase my books on computer programming and information technology in the following links below.
https://www.unlimitedbooksph.com/



Sample Program Output


Program Listing

ordinal.cpp

// ordinal.cpp
// Jake Rodriguez Pomperada
// May 26, 2020      Tuesday    10:51 PM

 #include <iostream>
 #include <string>

 using namespace std;
 
string ordinal(int i)
{
int mod100 = 0, mod10 = 0;

mod100 = (i % 100);
mod10 = (i % 10);
 
if (mod10 == 1 && mod100 != 11) {
return "st";
} else if (mod10 == 2 && mod100 != 12) {
 return "nd";
}
else if (mod10 == 3 && mod100 != 13) {
return "rd";
} else {
return "th";
 }
}

 int main()
 {
 
   int num_items = 0, sum = 0, num;
   
   cout <<"\n\n";
   cout <<"\tRunning Sum of Numbers Using Ordinal Indicators in C++";
   cout <<"\n\n";
   cout << "\tHow many items: ";
   cin >> num_items;
   for (int i = 1; i <= num_items; ++i)
  {
    cout << "\tGive value in the " << i << ordinal(i) << " item: ";
    cin >> num;
    sum += num;
   cout << "\tThe running sum is: " << sum << '\n';
   }
   cout <<"\n";
   cout <<"\tEnd of the Program";
   cout <<"\n";
 }




Monday, May 25, 2020

Print the Words Ending with Letter E in C Language

Print the Words Ending with Letter E in C programming language were written by my close friend and fellow software engineer Sir Ernel. Thank you sir Ernel for sharing your work with us.

I am currently accepting programming work inventory system, enrollment system, accounting system, payroll system, information system, website design and development using WordPress, 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. My telephone number at home here in Bacolod City, Negros Occidental Philippines is +63 (034) 4335675.

Here in Bacolod City, Negros Occidental I also accepting computer repair, web development using WordPress, Computer Networking, and Arduino Project development at a very affordable price. My personal website is http://www.jakerpomperada.com

My programming website is http://www.jakerpomperada.blogspot.comI am also a book author you can purchase my books on computer programming and information technology in the following links below.
https://www.unlimitedbooksph.com/


Program Listing

#include <stdio.h>
#include <string.h>
char str[100];
int main()
{
    int i, t, j, len;
    printf("Enter a string : ");
    scanf("%[^\n]s", str);
    len = strlen(str);
    str[len] = ' ';
    for (t = 0, i = 0; i < strlen(str); i++)
    {
        if ((str[i] == ' ') && (str[i - 1] == 'e'))
        {
            for (j = t; j < i; j++)
                printf("%c", str[j]);
            t = i + 1;
            printf("\n");
        }
        else
        {
            if (str[i] == ' ')
            {
                t = i + 1;
            }
        }
    }
    return 0;
}

Comparing C to machine language

Print tables from 2 to 10 by using nested for loop in C

Print tables from 2 to 10 by using nested for loop in C programming language were written by my close friend and fellow software engineer Sir Ernel. Thank you sir Ernel  for sharing your work with us.

I am currently accepting programming work inventory system, enrollment system, accounting system, payroll system, information system, website design and development using WordPress, 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. My telephone number at home here in Bacolod City, Negros Occidental Philippines is +63 (034) 4335675.

Here in Bacolod City, Negros Occidental I also accepting computer repair, web development using WordPress, Computer Networking, and Arduino Project development at a very affordable price. My personal website is http://www.jakerpomperada.com

My programming website is http://www.jakerpomperada.blogspot.comI am also a book author you can purchase my books on computer programming and information technology in the following links below.
https://www.unlimitedbooksph.com/


Program Listing

#include<stdio.h>
int main()
{
int num,i;
for(num=2;num<=10;num++)
{
printf("\nTable of %d\n",num);
for(i=1;i<=10;i++)
{
printf("\n%d * %d =%d",num,i,num*i);
}
printf("\n");
}
return 0;
}

Bjarne Stroustrup: Why I Created C++ | Big Think

James Gosling - Thoughts for Students

Math Operations Using Switch in C

Math operations using the switch in C programming language was written by my close friend and fellow software engineer Sir Ernel. Thank you sir Ernel  for sharing your work with us.

I am currently accepting programming work inventory system, enrollment system, accounting system, payroll system, information system, website design and development using WordPress, 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. My telephone number at home here in Bacolod City, Negros Occidental Philippines is +63 (034) 4335675.

Here in Bacolod City, Negros Occidental I also accepting computer repair, web development using WordPress, Computer Networking, and Arduino Project development at a very affordable price. My personal website is http://www.jakerpomperada.com

My programming website is http://www.jakerpomperada.blogspot.comI am also a book author you can purchase my books on computer programming and information technology in the following links below.
https://www.unlimitedbooksph.com/


Program Listing

#include<stdio.h>

int main()
{
int num1,num2,choice;
printf("\nEnter the two numbers\n");
scanf("%d %d",&num1,&num2);
printf("\n1 Addition");
printf("\n2 Subtraction");
printf("\n3 Multiplication");
printf("\n4 Division");
printf("\n5 Modulus");
printf("\nEnter the choice:");
scanf("%d",&choice);
switch(choice)
{
case 1:printf("\nThe Addition of two numbers is %d",num1+num2);
break;
case 2:printf("\nThe Subtraction of two numbers is %d",num1-num2);
break;
case 3:printf("\nThe Multiplication of two numbers is %d",num1*num2);
break;
case 4:printf("\nThe Division of two numbers is %d",num1/num2);
break;
case 5:printf("\nThe Modulus of two numbers is %d",num1%num2);
break;
default:printf("\nThis operation is not possible");
}
return 0;
}

Calendar in C

A calendar program was written by my close friend and fellow software engineer Sir Ernel. Thank you sir Ernel  for sharing your work with us.

I am currently accepting programming work inventory system, enrollment system, accounting system, payroll system, information system, website design and development using WordPress, 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. My telephone number at home here in Bacolod City, Negros Occidental Philippines is +63 (034) 4335675.

Here in Bacolod City, Negros Occidental I also accepting computer repair, web development using WordPress, Computer Networking, and Arduino Project development at a very affordable price. My personal website is http://www.jakerpomperada.com

My programming website is http://www.jakerpomperada.blogspot.comI am also a book author you can purchase my books on computer programming and information technology in the following links below.
https://www.unlimitedbooksph.com/


Program Listing

#include <stdio.h>
#include<stdlib.h>
#include <string.h>

char* months[] = {"Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec","Jan","Feb"};
char* days[]= { "sunday","monday", "tuesday", "wednesday", "thursday", "friday", "saturday" };
int Day(int date,int month,int year);
main()
{
 int k,m,year,i,flag=0,dates;
 char str[3],day[100];
 printf("Enter first 3 letters of month of the year ex:-for January enter Jan\n");
scanf("%s",str);
    for(i=0; i<12; i++)
    {
        if(!strcmp(str,months[i]))
        {
            m=i+1;
            flag=1;
            break;
        }
    }
  if(flag==0)
  {
    printf("Invalid Month\n");
    exit(0);
   }
  printf("Enter year\n");
  scanf("%d",&year);
    if(m==1 || m==3 || m==5 || m==6 || m==8 || m==10 || m==11)
     {
     dates=31;
     }
     if(m==2 || m==4 || m==7 || m==9)
     {
      dates=30;
     }
     if(m==12)
     {
          if(year%400==0)
          {
            dates=29;
          }
          else if(year%100==0)
          {
            dates=28;
          }
          else if(year%4==0)
          {
            dates=29;
          }
          else
          {
            dates=28;
          }
     }
 printf("-Sunday--Monday--Tuesday--Wednesday--Thursday--Friday--Saturday-\n");
 for(i=1;i<=dates;i++)
 {
  int finalday=Day(i,m,year);
  if(finalday==0)
  printf("%4d",i);
 if(finalday==1)
 {
  if(i!=1)
  printf("%8d",i);
  else
  printf("%12d",i);
 }
  if(finalday==2)
  {
   if(i!=1)
   printf("%8d",i);
   else
   printf("%20d",i);
  }
  if(finalday==3)
  {
   if(i!=1)
   printf("%9d",i);
   else
   printf("%29d",i);
  }
  if(finalday==4)
  {
   if(i!=1)
   printf("%11d",i);
   else
   printf("%40d",i);
  }
  if(finalday==5)
  {
   if(i!=1)
   printf("%10d",i);
   else
   printf("%50d",i);
  }
  if(finalday==6)
  {
   if(i!=1)
   printf("%8d\n",i);
   else
   printf("%58d\n",i);
  }
 }
printf("\n");
}
int Day(int k,int m,int year)
{
   int D,C,i,f,finalday,flag=0;
   char day[100];
   if(k<=0||k>31)
   {
     printf("Invalid Date\n");
     exit(0);
    }
    if(m==11||m==12)
     {
       year=year-1;
     }
     D=year%100;
     C=year/100;
     f = (k+(((13*m)-1)/5)+D+(D/4)+(C/4))-(2*C);
     if(f>=0)
     {
       finalday=f%7;
      }
      else
     {
       finalday=((f%7)+7)%7;
      }
      return(finalday);
}




Interest Loan Calculator in jQuery

In this article I share with you a simple interest loan calculator that I wrote using jQuery. I hope this can help you in your study of jQuery library.

I am currently accepting programming work inventory system, enrollment system, accounting system, payroll system, information system, website design and development using WordPress, 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. My telephone number at home here in Bacolod City, Negros Occidental Philippines is +63 (034) 4335675.

Here in Bacolod City, Negros Occidental I also accepting computer repair, web development using WordPress, Computer Networking, and Arduino Project development at a very affordable price. My personal website is http://www.jakerpomperada.com

My programming website is http://www.jakerpomperada.blogspot.comI am also a book author you can purchase my books on computer programming and information technology in the following links below.
https://www.unlimitedbooksph.com/


Program Listing

index.html

<html>
<head>
<title>Interest Calculator in JQuery</title>
<script src="jquery-3.2.1.min.js"></script>
<style>
body {
 background-color:white;
 font-family: arial;
 font-size:15px;
 font-weight:bold;
 }

 .input_bold {
    font-weight: bold;
 font-size:15px;
 color: red;
}

.left {
    width: 15%;
    float: left;
    text-align: right;
}
.right {
    width: 50%;
    margin-left: 10px;
    float:left;
}
</style> 
<script>
$(document).ready(function(){

 $("#solve").click(function(){
   
  var amt = $("#amt").val();
  var interest = $("#interest").val();
  var years = $("#years").val();
  
   remarks = (amt*interest*years/100)
 $("#results").val('PHP ' + remarks.toFixed(2));
 
 });

   $("#clear").click(function(){
   $("#amt").val('');
   $("#interest").val('');
   $("#years").val('');
   $("#results").val('');
   $("#amt").focus();
   });
 });
  
 </script>
</head>
<body>
<form>
<br>
<h3>Interest Calculator in jQuery</h3>
<div class="left">
 Amount Loaned
</div>
<div class="right">
 <input type="text" id="amt" size="10" autofocus/><br>
</div>
<br><br>
<div class="left">
 Interest Rate 
</div>
<div class="right">
 <input type="text" id="interest" size="10" /><br>
</div>
<br><br>
<div class="left">
 How many years
</div> 
<div class="right">
 <input type="text" id="years" size="10" />
</div> 
<br><br>
<div class="left">
 The interest is 
</div>
<div class="right">
 <input type="text" id="results" class="input_bold" size="10" readonly/><br>
</div>
 <br><br><br>
 <div class="left">
<button type= "button" id ="solve">Check </button>    
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
</div>
<div class="right">
<button type= "button" id ="clear">Clear </button> 
</div>
</form>
</body>
</html>