Final Requirement for        ProgrammingSwitch Case and Looping                http://eglobiotraining.com/
What is Programming?    Programming is coding, modeling,simulating or presenting the solution to aproblem, by representing...
A programming language is a stylizedcommunication technique intended to beused for controlling the behavior of machine(com...
The term programming language usuallyrefers to high-level languages, such asBASI, C, CC++, COBOL, FORTRAN, Ada, andPascal....
C Programming is a powerful systemprogramming language   C++ Programming is an excellentgeneral purpose programming langua...
As a student, I have to learn and understandprogramming, I have to be familiar with it.Because programming is one of the s...
Switch Case   Switch statement (aprogramming language) comparesthe value of an expression againsta list of integers or cha...
The switch case statement is useful programming and it is a better   way of writing a program when a series of if elses oc...
Rules for switch statements• values for case must be integer  or character• constants the order of the case  statements is...
Loops    A loop is a programming language, it is a way of repeating a statement a number of times until some way of ending...
Example of For Loop                  http://eglobiotraining.com/
Example of While Loop                   http://eglobiotraining.com/
Example of Do While Loop                    http://eglobiotraining.com/
The Codes and Explanations ofthe Program that I have tested             and         The Output   Program Using Dev C++    ...
Switch Case 1                http://eglobiotraining.com/
This is the output program of switch case 1.It says that there “Enter the day of the weekbetween 1-7”, if you enter a numb...
Switch Case 2                http://eglobiotraining.com/
This is the output program of switchcase 2.The first output shows that the numberentered is equal to n which isequivalent ...
Switch Case 3                http://eglobiotraining.com/
This is the output program of switch case 3.In programming, we can create statement that willask you to choose your answer...
Switch Case 4                http://eglobiotraining.com/
This is the output program of switch case 4.This program shows the computation of thescores of the student. It shows there...
Switch Case 5                http://eglobiotraining.com/
This is the output program of switch case 5.The program ask to enter a number between 1 to5, I entered 5 and the word five...
Looping 1            http://eglobiotraining.com/
This is the output program of Looping 1.Here, I used the for loop in making thisprogram. It shows there numbers startingfr...
Looping 2            http://eglobiotraining.com/
This is the output program of Loop 2.Programming can also createstatements like counting numbers, inthis program it ask to...
Looping 3            http://eglobiotraining.com/
This is the output program of Loop 3.In programming, we can create statement that will not stop unlessyou enter a valid va...
Looping 4            http://eglobiotraining.com/
This is the output program of Loop 4.There are some statements in programmingthat are easy to do, just like this one. It i...
Looping 5            http://eglobiotraining.com/
This is the output program of loop 5.We can also use programming in solving somemathematical problems. This is a while loo...
Submitted to:Prof. Erwin Globiohttp://eglobiotraining.com/Submitted by:Bonifacio, Mary Clemence A.BM10203                 ...
Upcoming SlideShare
Loading in...5
×

Final requirement for programming-Bonifacio, Mary Clemence

216

Published on

0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total Views
216
On Slideshare
0
From Embeds
0
Number of Embeds
0
Actions
Shares
0
Downloads
3
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

Final requirement for programming-Bonifacio, Mary Clemence

  1. 1. Final Requirement for ProgrammingSwitch Case and Looping http://eglobiotraining.com/
  2. 2. What is Programming? Programming is coding, modeling,simulating or presenting the solution to aproblem, by representing facts, data orinformation using pre-defined rules andsemantics, on a computer or any otherdevice for automation. Programming is the art and science oftranslating a set of ideas into a program - alist of instructions a computer can follow.The person writing a program is known as aprogrammer (also a coder). http://eglobiotraining.com/
  3. 3. A programming language is a stylizedcommunication technique intended to beused for controlling the behavior of machine(computer). Like human languagesprogramming languages have syntactic andsemantic rules used to define meaning. Thousands of different programminglanguages have been created and new onesare created every year. The development of programminglanguages follows closely the developmentof the physical and electronic processesused in today’s computers. http://eglobiotraining.com/
  4. 4. The term programming language usuallyrefers to high-level languages, such asBASI, C, CC++, COBOL, FORTRAN, Ada, andPascal. Each language has a unique set ofkeywords (words that programmingunderstands) and a special syntax fororganizing program instructions. High-level programming languages, whilesimple compared to human languages, aremore complex than the languages thecomputer actually understands, calledmachine languages. Each different type ofCPU has its own unique machine language. http://eglobiotraining.com/
  5. 5. C Programming is a powerful systemprogramming language C++ Programming is an excellentgeneral purpose programming language Dev-C++ is a specialized programmingtool which allows to edit and compile codesof applications based on C/C++. http://eglobiotraining.com/
  6. 6. As a student, I have to learn and understandprogramming, I have to be familiar with it.Because programming is one of the subjectsthat I’ am currently taking this semester. At first, I find programming very difficult andconfusing. You should know first the basic rulesin programming for you to understand it better.There are lots of things that you have toconsider in programming, especially whenentering the codes, you must be very carefulwith it. http://eglobiotraining.com/
  7. 7. Switch Case Switch statement (aprogramming language) comparesthe value of an expression againsta list of integers or characterconstants. The list of constantsare listed using the "case"statement along with a "break"statement to end the execution. http://eglobiotraining.com/
  8. 8. The switch case statement is useful programming and it is a better way of writing a program when a series of if elses occurs. The general format for this is,The keyword break must be included at the end of each case statement. The default clause is optional, and is executed if the cases are not met. The right brace at the end signifies the end of the case selections. http://eglobiotraining.com/
  9. 9. Rules for switch statements• values for case must be integer or character• constants the order of the case statements is unimportant• the default clause may occur first (convention places it last)• you cannot use expressions or ranges http://eglobiotraining.com/
  10. 10. Loops A loop is a programming language, it is a way of repeating a statement a number of times until some way of ending the loop occurs.These include following categories: 1. for loop 2. while loop 3. do while http://eglobiotraining.com/
  11. 11. Example of For Loop http://eglobiotraining.com/
  12. 12. Example of While Loop http://eglobiotraining.com/
  13. 13. Example of Do While Loop http://eglobiotraining.com/
  14. 14. The Codes and Explanations ofthe Program that I have tested and The Output Program Using Dev C++ http://eglobiotraining.com/
  15. 15. Switch Case 1 http://eglobiotraining.com/
  16. 16. This is the output program of switch case 1.It says that there “Enter the day of the weekbetween 1-7”, if you enter a number between1-7, the day that correspond to that numberwill appear. For example, you entered number3, Wednesday will appear because it is the 3rd http://eglobiotraining.com/
  17. 17. Switch Case 2 http://eglobiotraining.com/
  18. 18. This is the output program of switchcase 2.The first output shows that the numberentered is equal to n which isequivalent to 1,2,3. And the secondoutput shows that the number entered http://eglobiotraining.com/
  19. 19. Switch Case 3 http://eglobiotraining.com/
  20. 20. This is the output program of switch case 3.In programming, we can create statement that willask you to choose your answer from its choicesand will tell you what you have chose, just like theoutput above. Using switch case statement I find http://eglobiotraining.com/programming a little bit fun.
  21. 21. Switch Case 4 http://eglobiotraining.com/
  22. 22. This is the output program of switch case 4.This program shows the computation of thescores of the student. It shows there thename of the student, the total no. of scoreentered, the total score and the totalaverage score. http://eglobiotraining.com/
  23. 23. Switch Case 5 http://eglobiotraining.com/
  24. 24. This is the output program of switch case 5.The program ask to enter a number between 1 to5, I entered 5 and the word five appeared. http://eglobiotraining.com/
  25. 25. Looping 1 http://eglobiotraining.com/
  26. 26. This is the output program of Looping 1.Here, I used the for loop in making thisprogram. It shows there numbers startingfrom 0 to 10. http://eglobiotraining.com/
  27. 27. Looping 2 http://eglobiotraining.com/
  28. 28. This is the output program of Loop 2.Programming can also createstatements like counting numbers, inthis program it ask to count from 20 to http://eglobiotraining.com/45 by 5. This is a for loop statement.
  29. 29. Looping 3 http://eglobiotraining.com/
  30. 30. This is the output program of Loop 3.In programming, we can create statement that will not stop unlessyou enter a valid variable. The first output shows “please enter aninteger between 1 and 10”, if enter a valid number then theprogram will close. In the second output it shows there that in thefirst statement the number entered is invalid, the statement willkeep on repeating and it will only stop until you enter a valid http://eglobiotraining.com/number. This is a while loop statement.
  31. 31. Looping 4 http://eglobiotraining.com/
  32. 32. This is the output program of Loop 4.There are some statements in programmingthat are easy to do, just like this one. It is awhile loop statement, this program is onlysimple you can only see there the word http://eglobiotraining.com/“Hello”.
  33. 33. Looping 5 http://eglobiotraining.com/
  34. 34. This is the output program of loop 5.We can also use programming in solving somemathematical problems. This is a while loopstatement, as you can see there it asks you to“enter number of apples ate” this will show fivetimes every time you enter a number and the total http://eglobiotraining.com/
  35. 35. Submitted to:Prof. Erwin Globiohttp://eglobiotraining.com/Submitted by:Bonifacio, Mary Clemence A.BM10203 http://eglobiotraining.com/
  1. A particular slide catching your eye?

    Clipping is a handy way to collect important slides you want to go back to later.

×