Monday, April 20, 2009

The Blog Returns!

Haha. Nag-send na ako ng info on our groups on how to post here and other stuffs. Sana mabuhay ito hehe. Pero ewan, mukhang nakatatamad ding magpost lalo na kung busy mode na. Hehe.

Gusto ko na ring sabihin na miss ko na mga hindi ko na nakikita! Lalo na mga non-UPD/ADMU people. Paramdam kayo. Hehe.

Ayun lang for now. See you around.

Sunday, April 19, 2009

It's been quite a while, isn't it?

Can I just say?

HAHAHA, browse through this site and shet, hindi lang memories, laughtrip pa. HAHA. Shet, this was three-five years ago. WOW men. HAHA. Buti na lang naretrieve ko password ko sa blogger. Try ko rin retrieve password nito. May taong alam ba? Jobel? Yssa? Ewan ko na hehe.

Happy browsing!

--CaRLoHw c",)---

HAHAHA JOKE.

Sunday, November 12, 2006

ang tagal na...

syempre, wala ng nagpopost sa blog na ito..

ano nga ba ang bago sa PTOLEMY ngayon?

post something..something fierce, something edgy..haha

Wednesday, May 04, 2005

hey..

ngayon na lang ulit ako nakapunta dito.. may naguupdate pa rin pala nito kahit minsan minsan.. sana kahit hindi na tayo classmates, walang magbago sa ating pagsasamahan.. kaya sa may 8, wag niyong kakalimutan kung sinong may bday nun ha..

hehe.. miss ko na kayong lahat!!

", karen

Monday, May 02, 2005

miss you all :-)



MISS KO NA PTOLEMY!!!




sa lahat ng may blog, mag-update din kau!!





Jhek_09

Sunday, April 10, 2005

John 13:14

basahin nyo ito, mga classmates, alam kong problemado kayong lhat...

"I, your Lord and Teacher, have just washed your feet. You then should wash one another's feet." John 13:14

Jesus loved His disciples, so His disciples then should love each other.

LOVE, a magic word.what's this?

Sunday, March 27, 2005

LOVE (hindi po romance ito) Ü

hey classmates, baket wla nang nagpopost?? wla lang, tagal-tagal ko nang naghahanap ng update dito, kaso wala palagi... aww...

anyway... sana po ay kung meron man tayong hinanakit sa iba ay i-settle na natin... dhl alam kong maraming problema sa klase natin... alam nyo pa ba ung sinabi ni Jesus dun sa Gospel sa Last Supper(Washing of the Feet) nung Maundy Thursday, prang ganito un, pero di ito ung exact:


Love each other as I have loved you.


Para bang hugasan natin ung paa ng isa't isa tulad ng ginawa nya sa 12 apostles...

-->erialC<--

Friday, December 03, 2004

aCoH...

yey! i finally found the tym to post... uhmm... wat to post... wat to post... hhmmm... guyz! miz ko na kau...! parang 2 days pa lng taung di nagkikita... grabe! bwct nmang bagyong yan! pero on the bright syd, posponed yung mid-year... i just went shopping with my mom and sis a while ago... i bought a polka-dotted blue skirt with a cute belt... along with other stuff... talked with carlo in my brother's cellphone for about 30 minutes... [sun to sun cellular... 24/7?!]... waah! boring sa bahay! wahaha! bangag! ako?! oo, ako!! ü

ryanne_2726

Sunday, November 28, 2004

Does this mean "goodbye"?!

>Nov. 30, 2004 ---Ms. Maharlika Mojica's B-day...
Her last day of teaching,
Her last day of staying in MaSci!

The whole class is planning for their Despidida Party for their beloved adviser.

Hmmm, tears?!! :(

-JhEk_09

Sunday, November 21, 2004

papost lng ng cs proj

Alphanumeric

The user will input symbols and the program will determine how many numbers, letters (vowels and consonants), spaces and symbols are there.


#include "stdio.h"
#include "conio.h"
#include "string.h"
main ()
{char an[100];
int x,ctr,vowel,cons,alpha,num,symbol;
clrscr();
gotoxy (25,1);
printf ("Alphanumeric Detector");
printf ("\nEnter an alphanumeric combination now!\n");
gets (an);
ctr=strlen(an);
alpha=0;vowel=0;cons=0;num=0;symbol=0;
for (x=1;x<=ctr;x++) { switch (an[x]) { case 'a':case 'e':case 'i':case 'o':case 'u': case 'A':case 'E':case 'I':case 'O':case 'U': alpha+=1; vowel+=1; break; case 'B':case 'C':case 'D':case 'F':case 'G': case 'H':case 'J':case 'K':case 'L':case 'M':case 'N': case 'P':case 'R':case 'S':case 'T': case 'V':case 'W':case 'X':case 'Y':case 'Z': case 'b':case 'c':case 'd':case 'f':case 'g': case 'h':case 'j':case 'k':case 'l':case 'm':case 'n': case 'p':case 'r':case 's':case 't': case 'v':case 'w':case 'x':case 'y':case 'z': alpha+=1; cons+=1; break; case '1':case '2':case '3':case '4':case '5': case '6':case '7':case '9':case '8':case '0': num+=1; break; default: symbol=symbol+1; } } printf (" There are \n %d vowels\n %d consonants\n %d alphabets\n %d numbers\n %d symbols and spaces \n in your combination",vowel,cons,alpha,num,symbol); getche(); } Output: Alphanumeric Detector Enter an alphanumeric combination now! There are vowels consonants alphabets numbers symbols and spaces Physics: Electricity This program computes the resistance, voltage, current, given the information needed to do so. #include
#include
main()
{
float v, c, r, x;
char y;

clrscr();
printf("Choose From the 3 choices you want to do:");
printf("\n[1]Compute Voltage:");
printf("\n[2]Compute Current:");
printf("\n[3]Compute Resistance:\n");
scanf("%f", &x);
if (x==1)
{
printf("\nEnter value of Current:");
scanf("%f", &c);
printf("\nEnter value of Resistance:");
scanf("%f", &r);
v=c*r;
printf("\nVoltage is: %0.2f V", v);
}
else if (x==2){
printf("\nEnter value of Voltage:");
scanf("%f", &v);
printf("\nEnter value of Resistance:");
scanf("%f", &r);
c=v/r;
printf("\nCurrent is: %0.2f A", c);
}

else if (x==3){
printf("\nEnter value of Voltage:");
scanf("%f", &v);
printf("\nEnter value of Current:");
scanf("%f", &c);
r=v/c;
printf("\nResistance is: %0.2f W", r);


}
getche();
}


Output:
Choose from the 3 choices what you want to do:
[1]compute voltage:
[2]compute current:
[3]compute resistance:
1
Enter value of current:

Enter value of resistance:

Voltage is:





Inspirational Program

This program displays inspirational quotes relating to the user’s mood for the day.


#include
#include
main()
{
int choice;

clrscr ( )
printf (“Hi! How are you feeling today?”);
printf (“\n[1] Angry”);
printf (“\n[2] Depressed”);
printf (“\n[3] Happy ”);
printf (“\n[4] Fulfilled”);
printf (“\n[5] Loved”);
printf (“\n[6] Shy”);
printf (“\n[7] Tired”);
printf (“\n[8] Creative”);
printf (“\n[9] Relaxed”);
printf (“\n[10] Enthusiastic”);
printf (“\n\nEnter the number corresponding to your mood today:”);
scanf (“%d”,&choice);
switch (choice)
{
case 1:
clrscr();
printf(“\nAnger makes you smaller, while forgiveness forces you to grow beyond what you were. – Cherie Carter-Scott”);
break;
case 2:
clrscr();
printf(“\nWe must accept finite disappointment, but we must never lose infinite hope.-Martin Luther King”);
break;
case 3:
clrscr();
printf(“\nHappiness is not a destination. It is a method of life. –Burton Hills);
break;
case 4:
clrscr();
printf(“\nThe best and most beautiful things in this world cannot be seen or even
heard, but must be felt with the heart. – Helen Keller”);
break;
case 5:
clrscr();
printf(“\nTo love and be loved is to feel the sun from both sides. –David
Viscott”);
break;

case 6:
clrscr();
printf(“\nThe shell must break before the bird can fly. - Tennyson”);
break;
case 7:
clrscr();
printf(“\nOur real blessings often appear to us in the shapes of pains, losses and
disappointments; but let us have patience, and we soon shall see them in their
proper figures. - Joseph Addison.”);
break
case 8:
clrscr();
printf(“One must still have chaos in oneself to be able to give birth to a dancing star. –Nietzsche”);
break;
case 9:
clrscr();
printf (“There is more to life than increasing its speed.- Gandhi”);
break;
case 10:
clrscr();
printf (“Enthusiasm is contagious. Start an epidemic. –unknown”);
break:
}
printf (“\n\nwe hope you enjoyed our inspirational quote of the day.”);
getche();
}





Output:


Hi! How are you feeling today?
[1] Angry
[2] Depressed
[3] Happy
[4] Fulfilled
[5] Loved
[6] Shy
[7] Tired
[8] Creative
[9] Relaxed
[10] Enthusiastic

Enter the number corresponding to your mood today:3
Happiness is not a destination. It is a method of life.-Burton Hills

we hope you enjoyed our inspirational quote of the day.

Backward name

The user enters his/her name and the program prints it backwards


#include "stdio.h"
#include "conio.h"
main()
{char name[20];
clrscr();
printf ("Enter your name:");
gets (name);
printf ("Your name backwards is");
strrev (name);
printf ("\n%s",name);
getche();
}


Output:

Enter your name: Roddel
Your name backwards is
Leddor
Trivia Game

This is a game that is filled with questions and the user will answer them and the points are counted


#include
#include
main()
{char ans;
int choice,score;
clrscr();
printf ("This is the Trivia Game");
clrscr();
printf ("Please choose among the following categories:\n");
printf ("1)General Information\n");
printf ("2)Scientific Names of Animals\n");
printf ("3)Scientists\n");
printf ("4)Movies\n");
printf ("5)Exit(view the answers)");
scanf ("%d",&choice);
switch (choice)
{
case 1:
clrscr();
printf ("Question 1: What do you call the Japanese art of folding pieces of paper to form shapes in nature?\n");
printf ("a)Ikebana\n");
printf ("b)Origami\n");
ans=getche();
if (ans=='b') score+=1;
clrscr();
printf ("Question 2: Who built the first castle in 1078?\n");
printf ("a)William the Conqueror\n");
printf ("b)Lord Wilhelm John Roget\n");
ans=getche();
if (ans=='a') score+=1;
clrscr();
printf ("Question 3: What is the capital of Afghanistan?\n");
printf ("a)Baghdad\n");
printf ("b)Kabul\n");
ans=getche();
if (ans=='b') score+=1;
clrscr();
printf ("Question 4: Who founded Judaism?\n");
printf ("a)Guru nanak\n");
printf ("b)Abraham\n");
ans=getche();
if (ans=='b') score+=1;
clrscr();
printf ("Question 5: Is the tomato?\n");
printf ("a)a fruit\n");
printf ("b)a vegetable\n");
ans=getche();
if (ans=='b') score+=1;
clrscr();
if (score>=3)
printf ("You are the champion in this category!!!");
else printf ("sorry, you lost.....GAME OVER");
getche();
break;
case 2:
clrscr();
printf ("Question 1: What animal has the scientific name Mus musculus?\n");
printf ("a)cat\n");
printf ("b)mouse\n");
ans=getche();
if (ans=='b') score+=1;
clrscr();
printf ("Question 2: What is the scientific name of chicken?\n");
printf ("a)Gallus domesticus\n");
printf ("b)Gallus gallus\n");
ans=getche();
if (ans=='b') score+=1;
clrscr();
printf ("Question 3: What is a Capra hircus?\n");
printf ("a)goat\n");
printf ("b)toad\n");
ans=getche();
if (ans=='a') score+=1;
clrscr();
printf ("Question 4: Which is the scientific name of crocodile?\n");
printf ("a)Crocodylus niloticus\n");
printf ("b)Alligator mississipiensis\n");
ans=getche();
if (ans=='a') score+=1;
clrscr();
printf ("Question 5: What is a Crotalus horridus?\n");
printf ("a)a King cobra\n");
printf ("b)a Rattle snake\n");
ans=getche();
if (ans=='b') score+=1;
clrscr();
if (score>=3)
printf ("You are the champion in this category!!!");
else printf ("sorry, you lost.....GAME OVER");
getche();
break;

case 3:
clrscr();
printf ("Question 1: Who invented the sewing machine?\n");
printf ("a)Leo Hendrik Baekeland\n");
printf ("b)Elias Howe\n");
ans=getche();
if (ans=='b') score+=1;
clrscr();
printf ("Question 2: Samuel Colt invented a what?\n");
printf ("a)a practical revolver\n");
printf ("b)Junction Transistor\n");
ans=getche();
if (ans=='a') score+=1;
clrscr();
printf ("Question 3: Who invented the stethoscope?\n");
printf ("a)William Shockley\n");
printf ("b)Rene Laennec\n");
ans=getche();
if (ans=='b') score+=1;
clrscr();
printf ("Question 4: Who invented the direct current generator?\n");
printf ("a)George Stephenson\n");
printf ("b)Werener von Siemens\n");
ans=getche();
if (ans=='b') score+=1;
clrscr();
printf ("Question 5: What did Sir Charles Wheatstone invent?\n");
printf ("a)a printer\n");
printf ("b)the stereoscope\n");
ans=getche();
if (ans=='b') score+=1;
clrscr();
if (score>=3)
printf ("You are the champion in this category!!!");
else printf ("sorry, you lost.....GAME OVER");
getche();
break;
case 4:
clrscr();
printf ("Question 1: Who played the role of Doc Ock in the movie Spiderman 2?\n");
printf ("a)Willaem Dafoe\n");
printf ("b)Alfred Molina\n");
ans=getche();
if (ans=='b') score+=1;
clrscr();
printf ("Question 2: What character did Famke Jannsen play in the movie X-Men?\n");
printf ("a)Jean Gray\n");
printf ("b)Mystique\n");
ans=getche();
if (ans=='a') score+=1;
clrscr();
printf ("Question 3: Who played Stanley Epkis in the movie The Mask?\n");
printf ("a)Raul Julia\n");
printf ("b)Jim Carrey\n");
ans=getche();
if (ans=='b') score+=1;
clrscr();
printf ("Question 4: Who are the villains in the movie Batman and Robin?\n");
printf ("a)Penguin and The Riddler\n");
printf ("b)Poison Ivy and Mr. Freeze\n");
ans=getche();
if (ans=='b') score+=1;
clrscr();
printf ("Question 5: Is Demi Moore an 'Angel' ,according to the story ,in the movie Charlie's Angels:Full Throttle?\n");
printf ("a)no\n");
printf ("b)yes\n");
ans=getche();
if (ans=='b') score+=1;
clrscr();
if (score>=3)
printf ("You are the champion in this category!!!");
else printf ("sorry, you lost.....GAME OVER");
getche();
break;
default:
{
clrscr();
printf ("Thank you for using my program!\n");
printf ("The answers are:\n");
printf ("1)b\n");
printf ("2)a\n");
printf ("3)b\n");
printf ("4)b\n");
printf ("5)b\n");
break;
}
}
getche();
}


Output:


Please choose among the following categories:
1)General information
2)Scientific names of animals
3)Scientists
4)Movies
5)Exit (view the answers)


question 1: question 2:
a) a)
b) b)

question 3: question 4:
a) a)
b) b)

question 5: You are the champion in this category!!
a)
b)

Computing for body mass index (BMI)

The user will enter his/her weight and height. This program will calculate the user’ s body mass index and will give interpretations and recommendations based on the results.


#include
#include
#include
main()
{float w,h,bmass;
clrscr();
printf (“Enter your weight in kilograms:”);
scanf (“%f”,&w);
printf (“\nEnter your height in metres :”);
scanf (“%f”,&h);
bmass= w/ pow(2.0,h);
printf (“\nYour BMI is 0.2%f”,bmass);
if (bmass>=30)
{printf(“\nYou are obese class II);
printf (“\nYou must minimize intake of fatty foods and replace them with high-fiber organic fruits and vegetables. Keep in mind that obesity imposes health risks. Obesity targets diabetes, arterosclerosis, heart failure and even liver problems.You may consider a rigid diet and exercise program. Consult your physician and/or dietician for more help.”);
}
if (bmass>24 && bmass<30)>22 && bmass<25)>18 &&amp; BMI <23)>
#include
main()
{int ctr;
clrscr();
for(ctr=1;ctr<=100;ctr++) { gotoxy (35,11); printf("Loading %d%% ",ctr); gotoxy (ctr/5+30,13); printf (""); delay(50); } getche(); } Output: Loading 0% Name Meaning Displays a meaning for the name of the user #include
#include
#include
main()
{char name[10];
int ctr,x;
clrscr();
printf ("Type in your name: ");
gets (name);
ctr=strlen(name);
printf ("Your name stands for:\n");
for (x=0;x<=ctr;x++) printf ("\n%c",name[x]); for (x=0;x<=ctr;x++) { if (name[x]==0name[x]==1name[x]==2name[x]==3name[x]==4name[x]==5name[x]==6name[x]==7name[x]==8name[x]==9) { if (name[0]=='a'name[0]=='A') {gotoxy (5,4); printf ("- affirmative");} if (name[0]=='b'name[0]=='B') {gotoxy (5,4); printf ("- benevolent");} if (name[0]=='c'name[0]=='C') {gotoxy (5,4); printf ("- charming");} if (name[0]=='d'name[0]=='D') {gotoxy (5,4); printf ("- diplomatic");} if (name[0]=='e'name[0]=='E') {gotoxy (5,4); printf ("- eager");} if (name[0]=='f'name[0]=='F') {gotoxy (5,4); printf ("- faithful");} if (name[0]=='g'name[0]=='G') {gotoxy (5,4); printf ("- gallant");} if (name[0]=='h'name[0]=='H') {gotoxy (5,4); printf ("- high-spirited");} if (name[0]=='i'name[0]=='I') {gotoxy (5,4); printf ("- influential");} if (name[0]=='j'name[0]=='J') {gotoxy (5,4); printf ("- juvenile");} if (name[0]=='k'name[0]=='K') {gotoxy (5,4); printf ("- keen-observer");} if (name[0]=='l'name[0]=='L') {gotoxy (5,4); printf ("- lofty");} if (name[0]=='m'name[0]=='M') {gotoxy (5,4); printf ("- mild");} if (name[0]=='n'name[0]=='N') {gotoxy (5,4); printf ("- neat");} if (name[0]=='o'name[0]=='O') {gotoxy (5,4); printf ("- obedient");} if (name[0]=='p'name[0]=='P') {gotoxy (5,4); printf ("- promising");} if (name[0]=='q'name[0]=='Q') {gotoxy (5,4); printf ("- quizzical");} if (name[0]=='r'name[0]=='R') {gotoxy (5,4); printf ("- responsible");} if (name[0]=='s'name[0]=='S') {gotoxy (5,4); printf ("- saintly");} if (name[0]=='t'name[0]=='T') {gotoxy (5,4); printf ("- talented");} if (name[0]=='u'name[0]=='U') {gotoxy (5,4); printf ("- unconventional");} if (name[0]=='v'name[0]=='V') {gotoxy (5,4); printf ("- veritable");} if (name[0]=='w'name[0]=='W') {gotoxy (5,4); printf ("- warm-hearted");} if (name[0]=='x'name[0]=='X') {gotoxy (5,4); printf ("- x-factored");} if (name[0]=='y'name[0]=='Y') {gotoxy (5,4); printf ("- youthful");} if (name[0]=='z'name[0]=='Z') {gotoxy (5,4); printf ("- zealous");} if (name[1]=='a'name[1]=='A') {gotoxy (5,5); printf ("- affirmative");} if (name[1]=='b'name[1]=='B') {gotoxy (5,5); printf ("- benevolent");} if (name[1]=='c'name[1]=='C') {gotoxy (5,5); printf ("- charming");} if (name[1]=='d'name[1]=='D') {gotoxy (5,5); printf ("- diplomatic");} if (name[1]=='e'name[1]=='E') {gotoxy (5,5); printf ("- eager");} if (name[1]=='f'name[1]=='F') {gotoxy (5,5); printf ("- faithful");} if (name[1]=='g'name[1]=='G') {gotoxy (5,5); printf ("- gallant");} if (name[1]=='h'name[1]=='H') {gotoxy (5,5); printf ("- high-spirited");} if (name[1]=='i'name[1]=='I') {gotoxy (5,5); printf ("- influential");} if (name[1]=='j'name[1]=='J') {gotoxy (5,5); printf ("- juvenile");} if (name[1]=='k'name[1]=='K') {gotoxy (5,5); printf ("- keen-observer");} if (name[1]=='l'name[1]=='L') {gotoxy (5,5); printf ("- lofty");} if (name[1]=='m'name[1]=='M') {gotoxy (5,5); printf ("- mild");} if (name[1]=='n'name[1]=='N') {gotoxy (5,5); printf ("- neat");} if (name[1]=='o'name[1]=='O') {gotoxy (5,5); printf ("- obedient");} if (name[1]=='p'name[1]=='P') {gotoxy (5,5); printf ("- promising");} if (name[1]=='q'name[1]=='Q') {gotoxy (5,5); printf ("- quizzical");} if (name[1]=='r'name[1]=='R') {gotoxy (5,5); printf ("- responsible");} if (name[1]=='s'name[1]=='S') {gotoxy (5,5); printf ("- saintly");} if (name[1]=='t'name[1]=='T') {gotoxy (5,5); printf ("- talented");} if (name[1]=='u'name[1]=='U') {gotoxy (5,5); printf ("- unconventional");} if (name[1]=='v'name[1]=='V') {gotoxy (5,5); printf ("- veritable");} if (name[1]=='w'name[1]=='W') {gotoxy (5,5); printf ("- warm-hearted");} if (name[1]=='x'name[1]=='X') {gotoxy (5,5); printf ("- x-factored");} if (name[1]=='y'name[1]=='Y') {gotoxy (5,5); printf ("- youthful");} if (name[1]=='z'name[1]=='Z') {gotoxy (5,5); printf ("- zealous");} if (name[2]=='a'name[2]=='A') {gotoxy (5,6); printf ("- affirmative");} if (name[2]=='b'name[2]=='B') {gotoxy (5,6); printf ("- benevolent");} if (name[2]=='c'name[2]=='C') {gotoxy (5,6); printf ("- charming");} if (name[2]=='d'name[2]=='D') {gotoxy (5,6); printf ("- diplomatic");} if (name[2]=='e'name[2]=='E') {gotoxy (5,6); printf ("- eager");} if (name[2]=='f'name[2]=='F') {gotoxy (5,6); printf ("- faithful");} if (name[2]=='g'name[2]=='G') {gotoxy (5,6); printf ("- gallant");} if (name[2]=='h'name[2]=='H') {gotoxy (5,6); printf ("- high-spirited");} if (name[2]=='i'name[2]=='I') {gotoxy (5,6); printf ("- influential");} if (name[2]=='j'name[2]=='J') {gotoxy (5,6); printf ("- juvenile");} if (name[2]=='k'name[2]=='K') {gotoxy (5,6); printf ("- keen-observer");} if (name[2]=='l'name[2]=='L') {gotoxy (5,6); printf ("- lofty");} if (name[2]=='m'name[2]=='M') {gotoxy (5,6); printf ("- mild");} if (name[2]=='n'name[2]=='N') {gotoxy (5,6); printf ("- neat");} if (name[2]=='o'name[2]=='O') {gotoxy (5,6); printf ("- obedient");} if (name[2]=='p'name[2]=='P') {gotoxy (5,6); printf ("- promising");} if (name[2]=='q'name[2]=='Q') {gotoxy (5,6); printf ("- quizzical");} if (name[2]=='r'name[2]=='R') {gotoxy (5,6); printf ("- responsible");} if (name[2]=='s'name[2]=='S') {gotoxy (5,6); printf ("- saintly");} if (name[2]=='t'name[2]=='T') {gotoxy (5,6); printf ("- talented");} if (name[2]=='u'name[2]=='U') {gotoxy (5,6); printf ("- unconventional");} if (name[2]=='v'name[2]=='V') {gotoxy (5,6); printf ("- veritable");} if (name[2]=='w'name[2]=='W') {gotoxy (5,6); printf ("- warm-hearted");} if (name[2]=='x'name[2]=='X') {gotoxy (5,6); printf ("- x-factored");} if (name[2]=='y'name[2]=='Y') {gotoxy (5,6); printf ("- youthful");} if (name[2]=='z'name[2]=='Z') {gotoxy (5,6); printf ("- zealous");} if (name[3]=='a'name[3]=='A') {gotoxy (5,7); printf ("- affirmative");} if (name[3]=='b'name[3]=='B') {gotoxy (5,7); printf ("- benevolent");} if (name[3]=='c'name[3]=='C') {gotoxy (5,7); printf ("- charming");} if (name[3]=='d'name[3]=='D') {gotoxy (5,7); printf ("- diplomatic");} if (name[3]=='e'name[3]=='E') {gotoxy (5,7); printf ("- eager");} if (name[3]=='f'name[3]=='F') {gotoxy (5,7); printf ("- faithful");} if (name[3]=='g'name[3]=='G') {gotoxy (5,7); printf ("- gallant");} if (name[3]=='h'name[3]=='H') {gotoxy (5,7); printf ("- high-spirited");} if (name[3]=='i'name[3]=='I') {gotoxy (5,7); printf ("- influential");} if (name[3]=='j'name[3]=='J') {gotoxy (5,7); printf ("- juvenile");} if (name[3]=='k'name[3]=='K') {gotoxy (5,7); printf ("- keen-observer");} if (name[3]=='l'name[3]=='L') {gotoxy (5,7); printf ("- lofty");} if (name[3]=='m'name[3]=='M') {gotoxy (5,7); printf ("- mild");} if (name[3]=='n'name[3]=='N') {gotoxy (5,7); printf ("- neat");} if (name[3]=='o'name[3]=='O') {gotoxy (5,7); printf ("- obedient");} if (name[3]=='p'name[3]=='P') {gotoxy (5,7); printf ("- promising");} if (name[3]=='q'name[3]=='Q') {gotoxy (5,7); printf ("- quizzical");} if (name[3]=='r'name[3]=='R') {gotoxy (5,7); printf ("- responsible");} if (name[3]=='s'name[3]=='S') {gotoxy (5,7); printf ("- saintly");} if (name[3]=='t'name[3]=='T') {gotoxy (5,7); printf ("- talented");} if (name[3]=='u'name[3]=='U') {gotoxy (5,7); printf ("- unconventional");} if (name[3]=='v'name[3]=='V') {gotoxy (5,7); printf ("- veritable");} if (name[3]=='w'name[3]=='W') {gotoxy (5,7); printf ("- warm-hearted");} if (name[3]=='x'name[3]=='X') {gotoxy (5,7); printf ("- x-factored");} if (name[3]=='y'name[3]=='Y') {gotoxy (5,7); printf ("- youthful");} if (name[3]=='z'name[3]=='Z') {gotoxy (5,7); printf ("- zealous");} if (name[4]=='a'name[4]=='A') {gotoxy (5,8); printf ("- affirmative");} if (name[4]=='b'name[4]=='B') {gotoxy (5,8); printf ("- benevolent");} if (name[4]=='c'name[4]=='C') {gotoxy (5,8); printf ("- charming");} if (name[4]=='d'name[4]=='D') {gotoxy (5,8); printf ("- diplomatic");} if (name[4]=='e'name[4]=='E') {gotoxy (5,8); printf ("- eager");} if (name[4]=='f'name[4]=='F') {gotoxy (5,8); printf ("- faithful");} if (name[4]=='g'name[4]=='G') {gotoxy (5,8); printf ("- gallant");} if (name[4]=='h'name[4]=='H') {gotoxy (5,8); printf ("- high-spirited");} if (name[4]=='i'name[4]=='I') {gotoxy (5,8); printf ("- influential");} if (name[4]=='j'name[4]=='J') {gotoxy (5,8); printf ("- juvenile");} if (name[4]=='k'name[4]=='K') {gotoxy (5,8); printf ("- keen-observer");} if (name[4]=='l'name[4]=='L') {gotoxy (5,8); printf ("- lofty");} if (name[4]=='m'name[4]=='M') {gotoxy (5,8); printf ("- mild");} if (name[4]=='n'name[4]=='N') {gotoxy (5,8); printf ("- neat");} if (name[4]=='o'name[4]=='O') {gotoxy (5,8); printf ("- obedient");} if (name[4]=='p'name[4]=='P') {gotoxy (5,8); printf ("- promising");} if (name[4]=='q'name[4]=='Q') {gotoxy (5,8); printf ("- quizzical");} if (name[4]=='r'name[4]=='R') {gotoxy (5,8); printf ("- responsible");} if (name[4]=='s'name[4]=='S') {gotoxy (5,8); printf ("- saintly");} if (name[4]=='t'name[4]=='T') {gotoxy (5,8); printf ("- talented");} if (name[4]=='u'name[4]=='U') {gotoxy (5,8); printf ("- unconventional");} if (name[4]=='v'name[4]=='V') {gotoxy (5,8); printf ("- veritable");} if (name[4]=='w'name[4]=='W') {gotoxy (5,8); printf ("- warm-hearted");} if (name[4]=='x'name[4]=='X') {gotoxy (5,8); printf ("- x-factored");} if (name[4]=='y'name[4]=='Y') {gotoxy (5,8); printf ("- youthful");} if (name[4]=='z'name[4]=='Z') {gotoxy (5,8); printf ("- zealous");} if (name[5]=='a'name[5]=='A') {gotoxy (5,9); printf ("- affirmative");} if (name[5]=='b'name[5]=='B') {gotoxy (5,9); printf ("- benevolent");} if (name[5]=='c'name[5]=='C') {gotoxy (5,9); printf ("- charming");} if (name[5]=='d'name[5]=='D') {gotoxy (5,9); printf ("- diplomatic");} if (name[5]=='e'name[5]=='E') {gotoxy (5,9); printf ("- eager");} if (name[5]=='f'name[5]=='F') {gotoxy (5,9); printf ("- faithful");} if (name[5]=='g'name[5]=='G') {gotoxy (5,9); printf ("- gallant");} if (name[5]=='h'name[5]=='H') {gotoxy (5,9); printf ("- high-spirited");} if (name[5]=='i'name[5]=='I') {gotoxy (5,9); printf ("- influential");} if (name[5]=='j'name[5]=='J') {gotoxy (5,9); printf ("- juvenile");} if (name[5]=='k'name[5]=='K') {gotoxy (5,9); printf ("- keen-observer");} if (name[5]=='l'name[5]=='L') {gotoxy (5,9); printf ("- lofty");} if (name[5]=='m'name[5]=='M') {gotoxy (5,9); printf ("- mild");} if (name[5]=='n'name[5]=='N') {gotoxy (5,9); printf ("- neat");} if (name[5]=='o'name[5]=='O') {gotoxy (5,9); printf ("- obedient");} if (name[5]=='p'name[5]=='P') {gotoxy (5,9); printf ("- promising");} if (name[5]=='q'name[5]=='Q') {gotoxy (5,9); printf ("- quizzical");} if (name[5]=='r'name[5]=='R') {gotoxy (5,9); printf ("- responsible");} if (name[5]=='s'name[5]=='S') {gotoxy (5,9); printf ("- saintly");} if (name[5]=='t'name[5]=='T') {gotoxy (5,9); printf ("- talented");} if (name[5]=='u'name[5]=='U') {gotoxy (5,9); printf ("- unconventional");} if (name[5]=='v'name[5]=='V') {gotoxy (5,9); printf ("- veritable");} if (name[5]=='w'name[5]=='W') {gotoxy (5,9); printf ("- warm-hearted");} if (name[5]=='x'name[5]=='X') {gotoxy (5,9); printf ("- x-factored");} if (name[5]=='y'name[5]=='Y') {gotoxy (5,9); printf ("- youthful");} if (name[5]=='z'name[5]=='Z') {gotoxy (5,9); printf ("- zealous");} if (name[6]=='a'name[6]=='A') {gotoxy (5,10); printf ("- affirmative");} if (name[6]=='b'name[6]=='B') {gotoxy (5,10); printf ("- benevolent");} if (name[6]=='c'name[6]=='C') {gotoxy (5,10); printf ("- charming");} if (name[6]=='d'name[6]=='D') {gotoxy (5,10); printf ("- diplomatic");} if (name[6]=='e'name[6]=='E') {gotoxy (5,10); printf ("- eager");} if (name[6]=='f'name[6]=='F') {gotoxy (5,10); printf ("- faithful");} if (name[6]=='g'name[6]=='G') {gotoxy (5,10); printf ("- gallant");} if (name[6]=='h'name[6]=='H') {gotoxy (5,10); printf ("- high-spirited");} if (name[6]=='i'name[6]=='I') {gotoxy (5,10); printf ("- influential");} if (name[6]=='j'name[6]=='J') {gotoxy (5,10); printf ("- juvenile");} if (name[6]=='k'name[6]=='K') {gotoxy (5,10); printf ("- keen-observer");} if (name[6]=='l'name[6]=='L') {gotoxy (5,10); printf ("- lofty");} if (name[6]=='m'name[6]=='M') {gotoxy (5,10); printf ("- mild");} if (name[6]=='n'name[6]=='N') {gotoxy (5,10); printf ("- neat");} if (name[6]=='o'name[6]=='O') {gotoxy (5,10); printf ("- obedient");} if (name[6]=='p'name[6]=='P') {gotoxy (5,10); printf ("- promising");} if (name[6]=='q'name[6]=='Q') {gotoxy (5,10); printf ("- quizzical");} if (name[6]=='r'name[6]=='R') {gotoxy (5,10); printf ("- responsible");} if (name[6]=='s'name[6]=='S') {gotoxy (5,10); printf ("- saintly");} if (name[6]=='t'name[6]=='T') {gotoxy (5,10); printf ("- talented");} if (name[6]=='u'name[6]=='U') {gotoxy (5,10); printf ("- unconventional");} if (name[6]=='v'name[6]=='V') {gotoxy (5,10); printf ("- veritable");} if (name[6]=='w'name[6]=='W') {gotoxy (5,10); printf ("- warm-hearted");} if (name[6]=='x'name[6]=='X') {gotoxy (5,10); printf ("- x-factored");} if (name[6]=='y'name[6]=='Y') {gotoxy (5,10); printf ("- youthful");} if (name[6]=='z'name[6]=='Z') {gotoxy (5,10); printf ("- zealous");} if (name[7]=='a'name[7]=='A') {gotoxy (5,11); printf ("- affirmative");} if (name[7]=='b'name[7]=='B') {gotoxy (5,11); printf ("- benevolent");} if (name[7]=='c'name[7]=='C') {gotoxy (5,11); printf ("- charming");} if (name[7]=='d'name[7]=='D') {gotoxy (5,11); printf ("- diplomatic");} if (name[7]=='e'name[7]=='E') {gotoxy (5,11); printf ("- eager");} if (name[7]=='f'name[7]=='F') {gotoxy (5,11); printf ("- faithful");} if (name[7]=='g'name[7]=='G') {gotoxy (5,11); printf ("- gallant");} if (name[7]=='h'name[7]=='H') {gotoxy (5,11); printf ("- high-spirited");} if (name[7]=='i'name[7]=='I') {gotoxy (5,11); printf ("- influential");} if (name[7]=='j'name[7]=='J') {gotoxy (5,11); printf ("- juvenile");} if (name[7]=='k'name[7]=='K') {gotoxy (5,11); printf ("- keen-observer");} if (name[7]=='l'name[7]=='L') {gotoxy (5,11); printf ("- lofty");} if (name[7]=='m'name[7]=='M') {gotoxy (5,11); printf ("- mild");} if (name[7]=='n'name[7]=='N') {gotoxy (5,11); printf ("- neat");} if (name[7]=='o'name[7]=='O') {gotoxy (5,11); printf ("- obedient");} if (name[7]=='p'name[7]=='P') {gotoxy (5,11); printf ("- promising");} if (name[7]=='q'name[7]=='Q') {gotoxy (5,11); printf ("- quizzical");} if (name[7]=='r'name[7]=='R') {gotoxy (5,11); printf ("- responsible");} if (name[7]=='s'name[7]=='S') {gotoxy (5,11); printf ("- saintly");} if (name[7]=='t'name[7]=='T') {gotoxy (5,11); printf ("- talented");} if (name[7]=='u'name[7]=='U') {gotoxy (5,11); printf ("- unconventional");} if (name[7]=='v'name[7]=='V') {gotoxy (5,11); printf ("- veritable");} if (name[7]=='w'name[7]=='W') {gotoxy (5,11); printf ("- warm-hearted");} if (name[7]=='x'name[7]=='X') {gotoxy (5,11); printf ("- x-factored");} if (name[7]=='y'name[7]=='Y') {gotoxy (5,11); printf ("- youthful");} if (name[7]=='z'name[7]=='Z') {gotoxy (5,11); printf ("- zealous");} if (name[8]=='a'name[8]=='A') {gotoxy (5,12); printf ("- affirmative");} if (name[8]=='b'name[8]=='B') {gotoxy (5,12); printf ("- benevolent");} if (name[8]=='c'name[8]=='C') {gotoxy (5,12); printf ("- charming");} if (name[8]=='d'name[8]=='D') {gotoxy (5,12); printf ("- diplomatic");} if (name[8]=='e'name[8]=='E') {gotoxy (5,12); printf ("- eager");} if (name[8]=='f'name[8]=='F') {gotoxy (5,12); printf ("- faithful");} if (name[8]=='g'name[8]=='G') {gotoxy (5,12); printf ("- gallant");} if (name[8]=='h'name[8]=='H') {gotoxy (5,12); printf ("- high-spirited");} if (name[8]=='i'name[8]=='I') {gotoxy (5,12); printf ("- influential");} if (name[8]=='j'name[8]=='J') {gotoxy (5,12); printf ("- juvenile");} if (name[8]=='k'name[8]=='K') {gotoxy (5,12); printf ("- keen-observer");} if (name[8]=='l'name[8]=='L') {gotoxy (5,12); printf ("- lofty");} if (name[8]=='m'name[8]=='M') {gotoxy (5,12); printf ("- mild");} if (name[8]=='n'name[8]=='N') {gotoxy (5,12); printf ("- neat");} if (name[8]=='o'name[8]=='O') {gotoxy (5,12); printf ("- obedient");} if (name[8]=='p'name[8]=='P') {gotoxy (5,12); printf ("- promising");} if (name[8]=='q'name[8]=='Q') {gotoxy (5,12); printf ("- quizzical");} if (name[8]=='r'name[8]=='R') {gotoxy (5,12); printf ("- responsible");} if (name[8]=='s'name[8]=='S') {gotoxy (5,12); printf ("- saintly");} if (name[8]=='t'name[8]=='T') {gotoxy (5,12); printf ("- talented");} if (name[8]=='u'name[8]=='U') {gotoxy (5,12); printf ("- unconventional");} if (name[8]=='v'name[8]=='V') {gotoxy (5,12); printf ("- veritable");} if (name[8]=='w'name[8]=='W') {gotoxy (5,12); printf ("- warm-hearted");} if (name[8]=='x'name[8]=='X') {gotoxy (5,12); printf ("- x-factored");} if (name[8]=='y'name[8]=='Y') {gotoxy (5,12); printf ("- youthful");} if (name[8]=='z'name[8]=='Z') {gotoxy (5,12); printf ("- zealous");} if (name[9]=='a'name[9]=='A') {gotoxy (5,13); printf ("- affirmative");} if (name[9]=='b'name[9]=='B') {gotoxy (5,13); printf ("- benevolent");} if (name[9]=='c'name[9]=='C') {gotoxy (5,13); printf ("- charming");} if (name[9]=='d'name[9]=='D') {gotoxy (5,13); printf ("- diplomatic");} if (name[9]=='e'name[9]=='E') {gotoxy (5,13); printf ("- eager");} if (name[9]=='f'name[9]=='F') {gotoxy (5,13); printf ("- faithful");} if (name[9]=='g'name[9]=='G') {gotoxy (5,13); printf ("- gallant");} if (name[9]=='h'name[9]=='H') {gotoxy (5,13); printf ("- high-spirited");} if (name[9]=='i'name[9]=='I') {gotoxy (5,13); printf ("- influential");} if (name[9]=='j'name[9]=='J') {gotoxy (5,13); printf ("- juvenile");} if (name[9]=='k'name[9]=='K') {gotoxy (5,13); printf ("- keen-observer");} if (name[9]=='l'name[9]=='L') {gotoxy (5,13); printf ("- lofty");} if (name[9]=='m'name[9]=='M') {gotoxy (5,13); printf ("- mild");} if (name[9]=='n'name[9]=='N') {gotoxy (5,13); printf ("- neat");} if (name[9]=='o'name[9]=='O') {gotoxy (5,13); printf ("- obedient");} if (name[9]=='p'name[9]=='P') {gotoxy (5,13); printf ("- promising");} if (name[9]=='q'name[9]=='Q') {gotoxy (5,13); printf ("- quizzical");} if (name[9]=='r'name[9]=='R') {gotoxy (5,13); printf ("- responsible");} if (name[9]=='s'name[9]=='S') {gotoxy (5,13); printf ("- saintly");} if (name[9]=='t'name[9]=='T') {gotoxy (5,13); printf ("- talented");} if (name[9]=='u'name[9]=='U') {gotoxy (5,13); printf ("- unconventional");} if (name[9]=='v'name[9]=='V') {gotoxy (5,13); printf ("- veritable");} if (name[9]=='w'name[9]=='W') {gotoxy (5,13); printf ("- warm-hearted");} if (name[9]=='x'name[9]=='X') {gotoxy (5,13); printf ("- x-factored");} if (name[9]=='y'name[9]=='Y') {gotoxy (5,13); printf ("- youthful");} if (name[9]=='z'name[9]=='Z') {gotoxy (5,13); printf ("- zealous");} }} getche(); } Output: Type in your name: ekai Your name stands for: e-eager k-keen-observer a-affirmative i-influential Price list Problem: price list for a store #include "stdio.h" #include "conio.h" main() {clrscr(); gotoxy (18,1); printf ("Welcome to AMAF-GURABE Gen. Merchandise"); gotoxy (30,3); printf ("");
gotoxy (25,5);
printf ("Item");
gotoxy (45,5);
printf ("price");
gotoxy (20,7);
printf ("Nichrome Wire");
gotoxy (45,7);
printf ("P30.00/m");
gotoxy (20,8);
printf ("School Bag");
gotoxy (45,8);
printf ("P175.00");
gotoxy (20,9);
printf ("Scotch Tape");
gotoxy (45,9);
printf ("P9.00");
gotoxy (20,10);
printf ("Double Sided Tape");
gotoxy (45,10);
printf ("P25.00");
gotoxy (20,11);
printf ("Chess Board");
gotoxy (45,11);
printf ("P230.00");
gotoxy (20,12);
printf ("Poster");
gotoxy (45,12);
printf ("P15.00");
gotoxy (20,13);
printf ("PC Games CD");
gotoxy (45,13);
printf ("P100.00");
getche();
}


Output:


Welcome to AMAF-GURABE Gen. Merchandise



Item price
Nichrome wire P30.00/m
School bag P175.00
Scotch tape P9.00
Double sided tape P25.00
Chess board P230.00
Poster P15.00
PC Games CD P100.00
Receipt

Problem: following it up, make a receipt of the items bought by the customer


#include "stdio.h"
#include "conio.h"
main()
{ float n1,n2,n3,n4,n5,n6,n7;
int q1,q2,q3,q4,q5,q6,q7;
clrscr();
gotoxy (18,1);
printf ("Welcome to AMAF-GURABE Gen. Merchandise");
gotoxy (30,3);
printf ("");
gotoxy (5,5);
printf ("Item");
gotoxy (25,5);
printf ("Price");
gotoxy (40,5);
printf ("Quantity");
gotoxy (55,5);
printf ("Net price");
gotoxy (1,7);
printf ("Nichrome Wire");
gotoxy (25,7);
printf ("P30.00/m");
gotoxy (1,8);
printf ("School Bag");
gotoxy (25,8);
printf ("P175.00");
gotoxy (1,9);
printf ("Scotch Tape");
gotoxy (25,9);
printf ("P9.00");
gotoxy (1,10);
printf ("Double Sided Tape");
gotoxy (25,10);
printf ("P25.00");
gotoxy (1,11);
printf ("Chess Board");
gotoxy (25,11);
printf ("P230.00");
gotoxy (1,12);
printf ("Poster");
gotoxy (25,12);
printf ("P15.00");
gotoxy (1,13);
printf ("PC Games CD");
gotoxy (25,13);
printf ("P100.00");
gotoxy (40,7);
scanf ("%d",&q1);
gotoxy (40,8);
scanf ("%d",&q2);
gotoxy (40,9);
scanf ("%d",&q3);
gotoxy (40,10);
scanf ("%d",&q4);
gotoxy (40,11);
scanf ("%d",&q5);
gotoxy (40,12);
scanf ("%d",&q6);
gotoxy (40,13);
scanf ("%d",&q7);
n1=30*q1;
n2=175*q2;
n3=9*q3;
n4=25*q4;
n5=230*q5;
n6=15*q6;
n7=100*q7;
gotoxy (55,7);
printf ("P%0.2f",n1);
gotoxy (55,8);
printf ("P%0.2f",n2);
gotoxy (55,9);
printf ("P%0.2f",n3);
gotoxy (55,10);
printf ("P%0.2f",n4);
gotoxy (55,11);
printf ("P%0.2f",n5);
gotoxy (55,12);
printf ("P%0.2f",n6);
gotoxy (55,13);
printf ("P%0.2f",n7);
gotoxy (55,15);
printf ("_________");
gotoxy (55,16);
printf ("P%0.2f",n1+n2+n3+n4+n5+n6+n7);
getche();
}


Receipt
Problem: following it up, make a receipt of the items bought by the customer

#include "stdio.h"
#include "conio.h"
main()
{ float n1,n2,n3,n4,n5,n6,n7;
int q1,q2,q3,q4,q5,q6,q7;
clrscr();
gotoxy (18,1);
printf ("Welcome to AMAF-GURABE Gen. Merchandise");
gotoxy (30,3);
printf ("");
gotoxy (5,5);
printf ("Item");
gotoxy (25,5);
printf ("Price");
gotoxy (40,5);
printf ("Quantity");
gotoxy (55,5);
printf ("Net price");
gotoxy (1,7);
printf ("Nichrome Wire");
gotoxy (25,7);
printf ("P30.00/m");
gotoxy (1,8);
printf ("School Bag");
gotoxy (25,8);
printf ("P175.00");
gotoxy (1,9);
printf ("Scotch Tape");
gotoxy (25,9);
printf ("P9.00");
gotoxy (1,10);
printf ("Double Sided Tape");
gotoxy (25,10);
printf ("P25.00");
gotoxy (1,11);
printf ("Chess Board");
gotoxy (25,11);
printf ("P230.00");
gotoxy (1,12);
printf ("Poster");
gotoxy (25,12);
printf ("P15.00");
gotoxy (1,13);
printf ("PC Games CD");
gotoxy (25,13);
printf ("P100.00");
gotoxy (40,7);
scanf ("%d",&q1);
gotoxy (40,8);
scanf ("%d",&q2);
gotoxy (40,9);
scanf ("%d",&q3);
gotoxy (40,10);
scanf ("%d",&q4);
gotoxy (40,11);
scanf ("%d",&q5);
gotoxy (40,12);
scanf ("%d",&q6);
gotoxy (40,13);
scanf ("%d",&q7);
n1=30*q1;
n2=175*q2;
n3=9*q3;
n4=25*q4;
n5=230*q5;
n6=15*q6;
n7=100*q7;
gotoxy (55,7);
printf ("P%0.2f",n1);
gotoxy (55,8);
printf ("P%0.2f",n2);
gotoxy (55,9);
printf ("P%0.2f",n3);
gotoxy (55,10);
printf ("P%0.2f",n4);
gotoxy (55,11);
printf ("P%0.2f",n5);
gotoxy (55,12);
printf ("P%0.2f",n6);
gotoxy (55,13);
printf ("P%0.2f",n7);
gotoxy (55,15);
printf ("_________");
gotoxy (55,16);
printf ("P%0.2f",n1+n2+n3+n4+n5+n6+n7);
getche();
}


Output:
Welcome to AMAF-GURABE Gen. Merchandise



Item price Quantity Net price
Nichrome wire P30.00/m 1 P30.00
School bag P175.00 1 P175.00
Scotch tape P9.00 1 P9.00
Double sided tape P25.00 1 P25.00
Chess board P230.00 1 P230.00
Poster P15.00 1 P15.00
PC Games CD P100.00 1 P100.00


Budgetting

Problem: Budgeting a monthly income


#include "stdio.h"
#include "conio.h"
main()
{ float ue1,save1,food1,pm1,pm,mi,ue,save,food;
clrscr();
printf ("Budget");
printf ("\nEnter your monthly income: ");
scanf ("%f",&mi);
printf ("How much do you alot for(in %):");
printf ("\nFood: ");
scanf ("%f",&food);
gotoxy (25,4);
printf ("%");
printf ("\nUtilities Expenses:");
scanf ("%f",&ue);
gotoxy (25,5);
printf ("%");
printf ("\nSavings:");
scanf ("%f",&save);
gotoxy (25,6);
printf ("%");
printf ("\nPocket Money:");
scanf ("%f",&pm);
gotoxy (25,7);
printf ("%");
food1=(food/100)*mi;
ue1=(ue/100)*mi;
save1=(save/100)*mi;
pm1=(pm/100)*mi;
if (pm+save+ue+food==100)
{gotoxy (35,4);
printf ("%0.2f",food1);
gotoxy (35,5);
printf ("%0.2f",ue1);
gotoxy (35,6);
printf ("%0.2f",save1);
gotoxy (35,7);
printf ("%0.2f",pm1);}
else printf ("You are spending more than your income");
getche();
}

Output:
Budget
Enter your monthly income: 100
How much do you alot for (in%)
Food: 25 % 25.00
Utilities Expense: 25 % 25.00
Savings: 25 % 25.00
Pocket Money: 25 % 25.00





Military Time to 12 Hour Format

Problem: convert military time to 12 hour format

#include "stdio.h"
#include "conio.h"
main()
{ int hr,min;
clrscr();
gotoxy (29,3);
printf ("Time Converter");
gotoxy (20,5);
printf ("Enter the military time: ");
gotoxy (45,5);
scanf ("%d",&hr);
gotoxy (47,5);
printf (":");
gotoxy (48,5);
scanf ("%d",&min);
if (hr>12&&amp;amp;hr<24&&min<60) hr="hr-12;" min="=" hr="=" hr="12;" min="=" hr="hr;" min="=" choice="=" min="=" hr="=" min="=" choice="=" min="=" ctr="1;ctr<=" x="strcmp(pin,pin2);" x="=" ctr="3;}" choice="getche();" days="31;" choice2="getche();" choice2="=" days="29;" days="28;" days="31;" days="30;" days="31;" days="30;" days="31;" days="31;" days="30;" days="31;" days="30;" days="31;">
#include
main()
{int n1,n2,lcd;
clrscr();
printf ("Enter two integers: \n");
scanf ("%d",&n1);
scanf ("%d",&n2);
if (n1%n2==0)
lcd=n1;
else if (n2%n1==0)
lcd=n2;
else
lcd=n1*n2;
printf ("The LCD is: %d",lcd);
getche();
}
Output:
Enter two integers :
3 18
The LCD is : 3

Dividing Text
Using a series of delay and gotoxy, this program will display groups of text one by one.
#include
#include
#include
main()
{int x;
clrscr();
delay (2000);
gotoxy (30,8);
printf ("Here comes the most");
delay (1000);
gotoxy (33,9);
printf ("ELECTRIFYING!");
delay (1000);
gotoxy (35,10);
printf ("STUNNING!");
delay (1000);
gotoxy (35,11);
printf ("POWERFUL!");
delay (1000);
gotoxy (38,12);
printf ("and");
delay (1000);
gotoxy (28,13);
printf ("SHOCKING GROUP OF ALL...");
delay (2000);
gotoxy (32,14);
printf ("AMAF-GURABE!!!!");
delay (1000);
x=0;
while (x<16)>
#include
#include
main()
{int x;
clrscr();
x=0;
while (x<33)
{clrscr();
gotoxy (66-x,10);
printf ("Introducing...");
x++;
delay (100);}
x=0;
while (x<26)
{clrscr();
gotoxy (33,10);
printf ("Introducing...");
gotoxy (50-x,11);
printf ("The NEW SHAMPOO for the Family!");
x++;
delay (100);}
delay (2000);
gotoxy (29,13);
textcolor (RED+128);
cprintf ("** ENJOICE NATURAL **");
x=0;
delay (1000);
while (x<11)
{clrscr();
textcolor (WHITE);
gotoxy (33,10);
cprintf ("Introducing...");
gotoxy (25,11);
cprintf ("The NEW SHAMPOO for the Family!");
gotoxy (29,13);
textcolor (RED+128);
cprintf ("** ENJOICE NATURAL **");
gotoxy (36,25-x);
textcolor (WHITE);
cprintf ("Buy NOW!");
delay(100);
x++;}
getche ();
}