Tuesday, June 4, 2019

Year Level Checker Using If Else If Statement Using Ruby

Write a program to display the year level of students based on their year
entry number. Here are the given criteria: (using if-else-if statement)

Entry Number                     High School Status
1                                         Freshmen
2                                        Sophomore
3                                        Junior
4                                        Senior
Other entry number          Out of school youth

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.

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

Here in Bacolod I also accepting computer repair, networking and Arduino Project development at a very affordable price.

My personal website is http://www.jakerpomperada.com



Sample Program Output

Program Listing

# year_level.rb
# Author   : Jake Rodriguez Pomperada,BSCS,MAED-IT
# Date     : May 25, 2019   Saturday  6:02 AM
# Address  : Bacolod City, Negros Occidental
# Tools    : Eclipse IDE and Ruby Version 2.6.3
# Location : Bacolod City, Negros Occidental  
# Website  : http://www.jakerpomperada.com
# Emails   : jakerpomperada@gmai.com and jakerpomperada@yahoo.com
puts "\n\n"
print "\tYear Level Checker Using If Else If Statement";
puts "\n\n"
print "\tWhat is your name?  ";
persons_name = gets.chomp
print "\n";
print "\tEnter your year level now :  ";
year_level = gets.chomp
year_level = year_level.to_i;
print "\n\n";
print "\t===== DISPLAY RESULT ====="
print "\n\n";

if (year_level == 1)
  print("\tHi #{persons_name.upcase} you are Freshman Status.");
elsif (year_level == 2)
  print("\tHi #{persons_name.upcase} you are Sophomore Status.");  
 elsif (year_level == 3)
    print("\tHi #{persons_name.upcase} you are Junior Status.");  
 elsif (year_level == 4)
     print("\tHi #{persons_name.upcase} you are Senior Status.");  
else
   print("\tHi #{persons_name.upcase} you are Out of School Youth.");  
end

print "\n\n";
print "\tEND OF PROGRAM";
print "\n\n";



Persons Gender Checker Using Ruby

Write a program that will ask the user's name and allows the user to select its gender A - Male and B - Female 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.

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

Here in Bacolod I also accepting computer repair, networking and Arduino Project development at a very affordable price.

My personal website is http://www.jakerpomperada.com



Sample Program Output

Program Listing

# gender.rb
# Author   : Jake Rodriguez Pomperada,BSCS,MAED-IT
# Date     : May 24, 2019   Thursday  8:23 AM
# Address  : Bacolod City, Negros Occidental
# Tools    : Eclipse IDE and Ruby Version 2.6.3
# Location : Bacolod City, Negros Occidental  
# Website  : http://www.jakerpomperada.com
# Emails   : jakerpomperada@gmai.com and jakerpomperada@yahoo.com
puts "\n\n"
print "\tPersons Gender Checker";
puts "\n\n"
print "\tWhat is your name?  ";
persons_name = gets.chomp
print "\n";
print "\tGender [A] Male  [B] Female";
print "\n\n";
print "\tSelect your gender :  ";
gender = gets.chomp

print "\n\n";
print "\t===== DISPLAY RESULT ====="
print "\n\n";

if (gender.downcase == 'a')
  print ("\tHello #{persons_name.upcase} you are MALE.")
elsif (gender.downcase == 'b')
  print ("\tHello #{persons_name.upcase} you are FEMALE.")
end  


if (gender.downcase !='a' and gender.downcase !='b')
  print("\tHello #{persons_name.upcase} you have select a wrong option.\n\n")
  print("\tTry again please")    
end

print "\n\n";
print "\tEND OF PROGRAM";
print "\n\n";


Find the Day of the Week Using Ruby

Design a program that will ask the user to print day name of the week using if else if statement.

Number         Day

1              Monday
2              Tuesday
3              Wednesday
4              Thursday
5              Friday
6              Saturday
7              Sunday

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.

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

Here in Bacolod I also accepting computer repair, networking and Arduino Project development at a very affordable price.

My personal website is http://www.jakerpomperada.com



Sample Program Output


Program Listing

# days.rb
# Author   : Jake Rodriguez Pomperada,BSCS,MAED-IT
# Date     : May 25, 2019   Saturday  7:57 AM
# Address  : Bacolod City, Negros Occidental
# Tools    : Eclipse IDE and Ruby Version 2.6.3
# Location : Bacolod City, Negros Occidental  
# Website  : http://www.jakerpomperada.com
# Emails   : jakerpomperada@gmai.com and jakerpomperada@yahoo.com
puts "\n\n"
print "\tFind the Day of the Week";
puts "\n\n"
print "\tEnter Day Number (1-7) :  ";
day = gets.chomp
day = day.to_i;
print "\n\n";
print "\t===== DISPLAY RESULT ====="
print "\n\n";
if (day == 1)
  print "\tThe given number #{day} represents MONDAY."
elsif (day == 2)
  print "\tThe given number #{day} represents TUESDAY."
elsif (day == 3)
    print "\tThe given number #{day} represents WEDNESDAY."
elsif (day == 4)
    print "\tThe given number #{day} represents THURSDAY."
elsif (day == 5)
      print "\tThe given number #{day} represents FRIDAY."
elsif (day == 6)
    print "\tThe given number #{day} represents SATURDAY."
elsif (day == 7)
      print "\tThe given number #{day} represents SUNDAY."
else
  print "\tInvalid Input! Please select day between 1-7."
end
print "\n\n";
print "\tEND OF PROGRAM";
print "\n\n";

Character Value Checker in Ruby

 Write a program to check whether a character is an alphabet, digit or special character given by the user using nested if..else statement using Ruby 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.

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

Here in Bacolod I also accepting computer repair, networking and Arduino Project development at a very affordable price.

My personal website is http://www.jakerpomperada.com



Sample Program Output

Program Listing

# character.rb
# Author   : Jake Rodriguez Pomperada,BSCS,MAED-IT
# Date     : May 29, 2019  Wednesday 4:22 PM
# Address  : Bacolod City, Negros Occidental
# Tools    : Eclipse IDE and Ruby Version 2.6.3
# Location : Bacolod City, Negros Occidental  
# Website  : http://www.jakerpomperada.com
# Emails   : jakerpomperada@gmail.com and jakerpomperada@yahoo.com
puts "\n\n"
print "\tCharacter Value Checker";
print "\n\n"
print "\tEnter any character: ";
ch = gets.chomp
print "\n";
print "\t===== DISPLAY RESULT ====="
print "\n\n";
if ((ch >= 'a' && ch <= 'z') || (ch >= 'A' && ch <= 'Z'))
   print "\tThe given value #{ch.upcase} is an Alphabet";
elsif (ch >= '0' && ch <= '9');
   print "\tThe given value #{ch} is a Digit.";
else
  printf "\tThe given value #{ch} is a Special Character.";
end
print "\n\n";
print "\tEND OF PROGRAM";
print "\n\n";




Leap Year Program Using unless Using Ruby


Write a program that will ask the user to give a year and then the program will determine if the given year is a leap year or not a leap year using unless statement and display the result 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.

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

Here in Bacolod I also accepting computer repair, networking and Arduino Project development at a very affordable price.

My personal website is http://www.jakerpomperada.com



Sample Program Output


Program Listing

# leap.rb
# Author   : Jake Rodriguez Pomperada,BSCS,MAED-IT
# Date     : June 4, 2019   Tuesday  5:19 AM
# Address  : Bacolod City, Negros Occidental
# Tools    : Eclipse IDE and Ruby Version 2.6.3
# Location : Bacolod City, Negros Occidental  
# Website  : http://www.jakerpomperada.com
# Emails   : jakerpomperada@gmai.com and jakerpomperada@yahoo.com

puts "\n\n"
print "\tLeap Year Program Using unless";
puts "\n\n"
print "\tGive a Year  : ";
year = gets.chomp
year = year.to_i;

print "\n";
print "\t===== DISPLAY RESULT ====="
print "\n\n";
unless (((year % 4 == 0) && (year % 100 !=0)) || (year % 400==0))
  print("\tThe give year #{year} is NOT a LEAP year.\n\n");
else    
  print("\tThe give year #{year} is a LEAP year.\n\n");
end  
print "\tEND OF PROGRAM";
print "\n\n";




Bigger Number Program Using unless in Ruby

Design a program that will ask the user to give two numbers and then the program will check and determine which of the two number is much bigger in terms of value using unless statement and display the result 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.

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

Here in Bacolod I also accepting computer repair, networking and Arduino Project development at a very affordable price.

My personal website is http://www.jakerpomperada.com


Sample Program Output

Program Listing

# bigger.rb
# Author   : Jake Rodriguez Pomperada,BSCS,MAED-IT
# Date     : June 4, 2019   Tuesday  5:02 AM
# Address  : Bacolod City, Negros Occidental
# Tools    : Eclipse IDE and Ruby Version 2.6.3
# Location : Bacolod City, Negros Occidental  
# Website  : http://www.jakerpomperada.com
# Emails   : jakerpomperada@gmai.com and jakerpomperada@yahoo.com
puts "\n\n"
print "\tBigger Number Program Using unless";
puts "\n\n"
print "\tGive First Value  : ";
a = gets.chomp
a = a.to_i;

print "\tGive Second Value : ";
b = gets.chomp
b = b.to_i;

print "\n";
print "\t===== DISPLAY RESULT ====="
print "\n\n";
unless (b > a)
   print("\t#{a} is much bigger than #{b}.\n\n");
else    
   print("\t#{b} is much bigger than #{a}.\n\n");
end  
print "\tEND OF PROGRAM";
print "\n\n";





Legal Age Checker Using unless Statement in Ruby

Write a program that will ask the user's age using unless statement to check if the given age by the user is still a minor or already an adult and display the result 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.

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

Here in Bacolod I also accepting computer repair, networking and Arduino Project development at a very affordable price.

My personal website is http://www.jakerpomperada.com



Sample Program Output

Program Listing


# age.rb
# Author   : Jake Rodriguez Pomperada,BSCS,MAED-IT
# Date     : June 3, 2019   Monday  4:46 PM
# Address  : Bacolod City, Negros Occidental
# Tools    : Eclipse IDE and Ruby Version 2.6.3
# Location : Bacolod City, Negros Occidental  
# Website  : http://www.jakerpomperada.com
# Emails   : jakerpomperada@gmai.com and jakerpomperada@yahoo.com
puts "\n\n"
print "\tLegal Age Checker Using unless";
puts "\n\n"
print "\tWhat is your age?  ";
age = gets.chomp
age = age.to_i;

print "\n";
print "\t===== DISPLAY RESULT ====="
print "\n\n";

unless (age >= 18)
   print("\tYour age is #{age} years old.\n\n");
   print("\tYou are still a MINOR.")
else    
   print("\tYour age is  #{age} years old.\n\n");
   print("\tYou are already an ADULT.")
end  

print "\n\n";
print "\tEND OF PROGRAM";
print "\n\n";



Positive and Negative Number Checker Using unless in Ruby


Write a program that will ask the user to give a number using unless a statement to check if the given number is a positive or negative number 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.

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

Here in Bacolod I also accepting computer repair, networking and Arduino Project development at a very affordable price.

My personal website is http://www.jakerpomperada.com


Sample Program Output

Program Listing

# pos_neg.rb
# Author   : Jake Rodriguez Pomperada,BSCS,MAED-IT
# Date     : June 3, 2019   Monday  4:35 PM
# Address  : Bacolod City, Negros Occidental
# Tools    : Eclipse IDE and Ruby Version 2.6.3
# Location : Bacolod City, Negros Occidental  
# Website  : http://www.jakerpomperada.com
# Emails   : jakerpomperada@gmai.com and jakerpomperada@yahoo.com
puts "\n\n"
print "\tPositive and Negative Number Checker Using unless";
puts "\n\n"
print "\tGive a number  : ";
num = gets.chomp
num = num.to_i;

print "\n";
print "\t===== DISPLAY RESULT ====="
print "\n\n";

unless (num >= 0)
   print("\tThe given number #{num} is a NEGATIVE number.");
else    
   print("\tThe given number #{num} is a POSITIVE number.");
end  

print "\n\n";
print "\tEND OF PROGRAM";
print "\n\n";

Odd and Even Number Checker Using unless in Ruby


Write a program using if else statement to ask the user to give a number and then the program will check and determine if the given number by the user is odd or even number using unless conditional statement and displays 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.

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

Here in Bacolod I also accepting computer repair, networking and Arduino Project development at a very affordable price.

My personal website is http://www.jakerpomperada.com



Sample Program Output


Program Listing


# odd_even.rb
# Author   : Jake Rodriguez Pomperada,BSCS,MAED-IT
# Date     : May 30, 2019   Thursday  11:36 AM
# Address  : Bacolod City, Negros Occidental
# Tools    : Eclipse IDE and Ruby Version 2.6.3
# Location : Bacolod City, Negros Occidental  
# Website  : http://www.jakerpomperada.com
# Emails   : jakerpomperada@gmai.com and jakerpomperada@yahoo.com
puts "\n\n"
print "\tOdd and Even Number Checker Using unless";
puts "\n\n"

print "\tGive a number  : ";
num = gets.chomp
num = num.to_i;

print "\n";
print "\t===== DISPLAY RESULT ====="
print "\n\n";

unless (num % 2 == 0)
   print("\tThe given number #{num} is a ODD number.");
else    
   print("\tThe given number #{num} is a EVEN number.");
end  

print "\n\n";
print "\tEND OF PROGRAM";
print "\n\n";