Iterative Statement - Problem on C Programming
What is the screen output of the ff. program? #include main() { int x,y; for (x=2;x<=4;x++) for(y=5;y>=3;y--) printf("%d\n",x+y); getch(); }Output:76
5
8
7
6
9
8
7
_Labels: eRnz
C Program using FOR Statement
Problem: Write a program that will print the numbers 1 to 10 using a FOR Statement. Program:#include"stdio.h"int x;main( ){ for (x=1;x<=10;x++)printf ("%d"\n",x);getch( );}Output:12345678910Labels: eRnz
C Programming Lesson - Iterative (Looping) Statements
CHAPTER 10
Have a nice day!
Labels: eRnz
Adsense Highest Paying Keywords
PURCHASE STRUCTURED SETTLEMENT keyword is rank 1 which has a cost per click or CPC $53.48.
MESOTHELIOMA LAWYERS SAN DIEGO keyword is rank 2 which has has a cost per click or CPC of $51.47.
Source:
www.tareeinternet.comLabels: eRnz
C Program using Conditional Statements
Problem:XYZ Company gives year-end bonus to its employees based on their number of years of service and their salary, using the following: Years of Service wwwwwwwwwwwwwwwwwwwwwBonus 1 wwwwwwwwwwwwwwwwwwwwwwwwwwwwww10% of Salary 2 to 4 wwwwwwwwwwwwwwwwwwwwwwwwwwww20% of Salary 5 to 10 wwwwwwwwwwwwwwwwwwwwwwwwwww50% of Salary 11 and above wwwwwwwwwwwwwwwwwwwwwww 75% of SalaryProgram:
( Click the image to enlarge)Labels: eRnz
Planetarium Zero-Zero
I know lots of people go to SM Mall of Asia in Pasay City to go malling. But only a few could go sleeping in MoA.
And by chance, we are one of those.Anyway the story was like this. We had our National PSYSC Science Olympiad Finals sa Nido Fortified Science Discovery Center sa Entertainment Mall nang nagsimula ang hagupit ni Ondoy. Then the MoA people advised the PSYSC facis not to permit us to go back to our residences dahil naging ilog na yung mga daan, like Roxas Boulevard, EDSA, the like.So, all of us (about 250 heads), including the participants, coaches, parents and the facis, plus the SDC staff, stayed on MoA.At anong ginawa namin? Most went to the Planetarium, dahil binigyan kami ng free movie marathon for about four hours, then sleeping time after that. Nakatutok naman yung iba sa TV (yung iba sa projector screen sa Events Center) to watch news updates about the typhoon. At yung iba, natulog na lamang, hoping na sana makakauwi na the morning after.And so it was. Most of us went home the morning after. We went out in MoA at exactly 0600.So three lessons learned on this funny yet once-in-a-lifetime (?) experience:
- Stay calm.
- Enjoy the place.
- Eat well.
"Cabin crew, prepare for take-off."smsanch >
Sample C Program on Conditional Statements
Problem: Write a C program that finds the smallest among the five integers inputted by the user. Program: (click the image to enlarge)
Labels: eRnz
C Programming Lesson - Conditional Statements
Chapter 8
Labels: eRnz