Friday, March 2, 2018

Perfect Number in C

In this article is another simple program to show you how to solve perfect number using C language. The code is very simple and easy to understand I am using Code Blocks to write this code.

I am currently accepting programming and web development work kindly contact me in the following email address for further details. Thank you.

My email address are the following jakerpomperada@gmail.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 is  +63 (034) 4335675.





Sample Program Output



Program Listing

perfect.c

#include <stdio.h>

int main()
{
    int number=0, rem=0, sum = 0, a=0;

    printf("Perfect Number in C");
    printf("\n\n");
    printf("Enter a Number : ");
    scanf("%d", &number);
    for (a = 1; a <= (number - 1); a++)
    {
        rem = (number % a);
if (rem == 0)
        {
            sum = sum + a;
        }
    }
    if (sum == number) {
        printf("\n\n");
        printf("The given number %d is perfect number.", number);
        printf("\n\n");
    }
    else {
        printf("\n\n");
        printf("The given number %d is not a perfect number.",number);
        printf("\n\n");
    }
     printf("\n\n");
    return 0;

}



Student Record System in C++

A very simple code to accept and display student profile using C++. I am using structure to hold and display it to the screen.

I am currently accepting programming and web development work kindly contact me in the following email address for further details. Thank you.

My email address are the following jakerpomperada@gmail.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 is  +63 (034) 4335675.



Program Listing

struct.cpp


#include <iostream>

using namespace std;

struct new_person {
    string name,address;
    int age;
};

main() {
    new_person sample;

    cout << "Enter your name : ";
    getline(cin,sample.name);
    cout << "\nEnter your Address : ";
    getline(cin,sample.address);
    cout << "\nEnter your Age : ";
    cin >> sample.age;


    cout << "\n\nName    : " << sample.name;
    cout << "\n\nAddress : " << sample.address;
    cout << "\n\nAge     : " << sample.age;
    cout << "\n\n";
    system("pause");
}

Student Grading System Using Text File in C++

A very simple program that I wrote a long time ago to compute and store the student grade in a text file using C++. I am using Code Blocks as my text editor and Dev C++ as my C++ compiler in this program.

I am currently accepting programming and web development work kindly contact me in the following email address for further details. Thank you.

My email address are the following jakerpomperada@gmail.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 is  +63 (034) 4335675.



Program Listing.

student_grade.cpp

#include <iostream>
#include <fstream>

using namespace std;

float grade(float pre, float med, float end)
{
   float compute=0;
  compute = (pre * 0.30) + (med * 0.30) + (end * 0.40);
  return(compute);
}

 main() {
      ofstream myfile("grade.txt");
      string name,course;
      float pre1=0.00, med1=0.00,end1=0.00;
      cout << "\n\t Student Grading System 1.0";
      cout << "\n\n";
      cout << "Enter Student Name    : ";
      getline(cin,name);
      cout << "Enter Student Course : ";
      getline(cin,course);
      cout << "Enter Prelim Grade    : ";
      cin >> pre1;
      cout << "Enter Midterm Grade   : ";
      cin >> med1;
      cout << "Enter Midterm Grade   : ";
      cin >> end1;
      cout << "\n\n";
      cout << "Final Grade "
           << grade(pre1,med1,end1)
           << ".";
      cout << "\n\n";
      myfile << "\n======================";
      myfile << "\n Student Grade Report ";
      myfile << "\n====================== ";
      myfile << "\n\n";
      myfile << "\nStudent Name   : " << name;
      myfile << "\nStudent Course : " << course;
      myfile << "\n\n";
      myfile << "\nPrelim  Grade   : " << pre1;
      myfile << "\nMidterm Grade   : " << med1;
      myfile << "\nEndterm Grade   : " << end1;
      myfile << "\n\n";
      myfile << "Final Grade "
           << grade(pre1,med1,end1)
           << ".";
      myfile.close();
      system("pause");
 }


Stack Function Call in C

A very simple program in C language to show how to call a function using stack.

I am currently accepting programming and web development work kindly contact me in the following email address for further details. Thank you.

My email address are the following jakerpomperada@gmail.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 is (034) 4335675.




Program Listing

#include <stdio.h>
#include <conio.h>
#include <stdlib.h>
#include <dos.h>

unsigned int far *ptr ;
void ( *p )( void ) ;

void f1( ) ;
void f2( ) ;

void main( )
{
f1( ) ;
f2( ) ;

printf ( "\nback to main..." ) ;
exit ( 1 ) ;
}

void f1( )
{
ptr = ( unsigned int far * ) MK_FP ( _SS, _SP + 2 ) ;
printf ( "\n%d", *ptr ) ;

p = ( void ( * )( ) ) MK_FP ( _CS, *ptr ) ;
( *p )( ) ;
printf ( "\nI am f1( ) function " ) ;
}

void f2( )
{
printf ( "\nI am f2( ) function" ) ;
}




Tuesday, February 27, 2018

Palindrome Checker in C

Here is a simple program that will ask the user to give a string and our program will check if the given string is a Palindrome or not Palindrome using C language.

I am currently accepting programming and web development work kindly contact me in the following email address for further details. Thank you.

My email address are the following jakerpomperada@gmail.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 is (034) 4335675.




Sample Program Output


Program Listing

palindrome.c

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

int main()
{
   char str_name[100], b[100];

   printf("PALINDROME CHECKER IN C ");
   printf("\n\n");
   printf("Give a String : ");
   gets(str_name);

   strcpy(b,str_name);
   strrev(b);

   if (strcmp(str_name,b) == 0) {
      printf("\n\n");
      printf("The given string %s is a palindrome.\n",str_name);
      }
   else{
       printf("\n\n");
       printf("The given string %s is not a palindrome.\n",str_name);
       }
   return 0;
}




Prime Number Checker in JQuery

In this article I would like to share with you a sample program to accept a number from our user and then our program will check if the given number in a Prime Number or Not a Prime Number using JQuery.

I am currently accepting programming and web development work kindly contact me in the following email address for further details. Thank you.

My email address are the following jakerpomperada@gmail.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 is (034) 4335675.




Sample Program Output


Program Listing

<!DOCTYPE html>
<html>
<head>
<script src="https://ajax.aspnetcdn.com/ajax/jQuery/jquery-3.3.1.min.js">
</script>
  <meta charset="utf-8">
  <style>
    body {
         background-color: lightgreen;
         font-family: arial;
         font-size: 15px;

    }
  </style>
  <script>
    $(document).ready(function() {
       var res = 0;
         
         var number = parseInt($("#txtnum").val());
         $("#txtnum").keypress(function(e) {

           if (e.which >= 48 && e.which <= 57) {
                
           }
           else {
             $("#error").html("Please enter only number number").show().fadeOut("slow");
             return false;
           }
         });
         $("#check").click(function() {
             res = 0;
             var number = parseInt($("#txtnum").val());
         
           for (var i = 1; i < number; i++) {
             if (number % i == 0) {
               res++;
             }
           };
             console.log(res);
           if (res >= 2) {
             $("#error").html("The given number is not a prime number.").show().fadeOut(5000);
             return false;
           }
           else {
             $("#error").html("The given number is a prime number.").show().fadeOut(5000);
           };
         });
       });
  </script>
</head>
<body>
    <table align="left">
    
    <tr>
      <td>
      </td>
      <td align="left">
          <h2>PRIME NUMBER CHECKER IN JQUERY</h2>
      </td>
      <td>
      </td>
    </tr>
    <tr>
      <td>
       Give a Number
      </td>
      <td>
        <input type="text" id="txtnum">
      </td>
      <td>
        <span id="error"> </span>
      </td>
    </tr>
    <tr>
      <td>
      </td>
      <td align="left">
         <input type="submit" value="Check Number" id="check">
      </td>
      <td>
      </td>
    </tr>
  </table>
</body>
</html>



Making Text Bold and Color Red Text in JQuery

Here is a simple code that I wrote that will make the text bold and red using JQuery. The code is very simple and easy to understand.


I am currently accepting programming and web development work kindly contact me in the following email address for further details. Thank you.

My email address are the following jakerpomperada@gmail.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 is (034) 4335675.



Sample Program Output


Program Listing

<!DOCTYPE html>
<html>
<head>
<script src="https://ajax.aspnetcdn.com/ajax/jQuery/jquery-3.3.1.min.js">
</script>
  <meta charset="utf-8">
  <script>
    $( document ).ready(function() {
      $('.ui-dialog-title').css({ 'font-weight': 'bold' });
       $('.ui-dialog-title').css({ 'color': 'red' });                          
    });
  </script>
</head>
<body>
    <div class="ui-dialog-title">
    Tonight, we dine in hell. </div>
</body>
</html>

Friday, February 23, 2018

Prime Number Checker in Visual Foxpro


A simple program that I wrote using Microsoft Visual Foxpro 9 that will ask the user to give a number and then our program will check if the given number is a Prime or Not a Prime Number. The code is very easy to understand and use.

I am currently accepting programming and web development work kindly contact me in the following email address for further details. Thank you.

My email address are the following jakerpomperada@gmail.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 is (034) 4335675.




Sample Program Output


Program Listing



Object: Form1    Procedure: Init
==============

thisform.txtvalue.Value=0

Check Button
=============
Object: Command1    Procedure: Click

 IF  empty(thisform.txtvalue.Value) 
     MESSAGEBOX("Can't be empty")
     thisform.txtvalue.Value=0
     thisform.txtvalue.SetFocus
     RETURN .t.
  ENDIF
  
  
  a=0
  for i=thisform.txtvalue.value to 1 step -1
  if MOD(thisform.txtvalue.value,i)=0
  a=a+1 
  ENDIF
  endfor
 
 if a=2 AND a#1
  display_result="The given number " + transform(thisform.txtvalue.value)+" is a Prime number."
  else
   display_result="The given number " +transform(thisform.txtvalue.value)+" is not a Prime number"
  endif
  thisform.label2.Caption = display_result
  
  
Check Button
==================
Object: Command2    Procedure: Click

 thisform.label2.Caption=""
 thisform.txtvalue.Value=0
 thisform.txtvalue.setfocus

 Quit Button
==================
Object: Command3    Procedure: Click

thisform.release




Addition and Subtraction of Two Numbers in PHP

Here is a sample program that I wrote that will accept  two numbers from the user and then it will add and subtract the two value given by the user using PHP as my programming language.

I am currently accepting programming and web development work kindly contact me in the following email address for further details. Thank you.

My email address are the following jakerpomperada@gmail.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 is (034) 4335675.





Sample Program Output


Program Listing

index.php

<html>
<head>
 <title>
    Addition  and Subtract of Two Numbers in PHP
 </title>
 <style>
   body {

    background-color: lightgreen;
    font-family: arial;
    font-weight: bold;
    font-size: 15px;
   }


#textInput2 {
    width:170px;
    height:100px;
    margin-left:5px;
 }
 </style>
 </head>
  <?php
  error_reporting(0);
  $x=$_POST['num1'];      
  $y=$_POST['num2']; 

  if(isset($_POST['clear']))
{
             
$x="";
$y="";   
      
}
?>  
<body>
<br><br><br>
<h1> Addition and Subtract of Two Numbers in PHP </h1>
<br><br>
<form method="post">

<label id="textInput2"> Enter first number </label>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<input  type="text" name="num1" value="<?php echo $x; ?>" autofocus/>
<br><br>
<label id="textInput2">
 Enter second number </label>
&nbsp;&nbsp;&nbsp;
 <input  type="text" name="num2" value="<?php echo $y; ?>"/>          
<br><br>
<input type="submit"  name="add" value="ADD"/> &nbsp; &nbsp;
<input type="submit"  name="subtract" value="SUBTRACT"/> &nbsp; &nbsp;
<input type="submit"  name="clear"  value="CLEAR"/> 
<br><br><br>
</form>
<?php       
if(isset($_POST['add']))
{
             
$sum=$x+$y;      
echo "Result:
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<input type='text' value='$sum'/ readonly>";            
}

if(isset($_POST['subtract']))
{
             
$subtract=$x-$y;      
echo "Result:
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<input type='text' value='$subtract'/ readonly>";            
}

?>
</body>
</html>




Thursday, February 22, 2018

Custom Software Development Services


Bacolod IT Software Solution and Consultancy

Do you have a problem in your organization in terms of managing your information. We are offering the following IT solution services at a very affordable price and very fast service here in Bacolod City.

Customized Software Development

Services Offered:

1. Custom Software Development
  (Accounting System, 
  Production Management System, 
  Personnel Information System,
  Website Development, 
 Lending System, 
 e-Governance,
  Payroll System, 
 Point of Sale, 
Clinical Information System,
 Medical Laboratory System,
 Sales and Inventory System,
 Enrolment System) 

2. Computer Repair and Maintenance

3. Computer Tutorials
   (Computer Programming,
    Web Development,
    Android Application Development)

4. IT Consultancy

5. Computer Networking And Administration


For more information you can send us an email at the following email address below.

jakerpomperada@yahoo.com

jakerpomperada@gmail.com

You can also reach me in my mobile number 09173084360 or telephone number (034) 4335675.

Thank you.