CH01.ppt - Chapter 1 Ruby Basics Ruby Programming Project Preview The Ruby Joke Game Ruby Programming 1-2 The Ruby Joke Game(continued When the game is

CH01.ppt - Chapter 1 Ruby Basics Ruby Programming Project...

This preview shows page 1 - 9 out of 22 pages.

Chapter 1 Ruby Basics Ruby Programming
Ruby Programming 1-2 Project Preview: The Ruby Joke Game
Ruby Programming 1-3 The Ruby Joke Game (continued) When the game is first started, the player is prompted for permission to begin telling jokes. Figure 1-1 The player may elect to play the game or quit.
Ruby Programming 1-4 The Ruby Joke Game (continued) If players enter a value of n, they’re invited to return to play another time. If they enter a value of y, the game begins displaying jokes. Figure 1-2 The player must press Enter to advance from screen to screen during game play.
Ruby Programming 1-5 The Ruby Joke Game (continued) In order to view the first joke’s punch line, the player must press the Enter key, after which the screen shown in Figure 1.3 displays. Figure 1-3 The punch line for the game’ s first joke.
Ruby Programming 1-6 The Ruby Joke Game (continued) To advance to and view successive jokes, the player must continue to press Enter. Once the final joke is told, the screen shown in Figure 1-4 displays. Figure 1-4 The game ends by thanking the player.
Ruby Programming 1-7 A Brief History of Computers and Computer Programming
Ruby Programming 1-8 The First Generation 1937 to 1953 is regarded as being the first generation of electronic computer systems. The British created Colossus in 1943 for breaking German military code in WWII. THE U.S. created Electronic Numerical Integrator and Computer (ENIAC) for computing ballistics in WWII and later used it to perform calculations as part of the development of the hydrogen bomb. The first computer programs were all written in machine language (machine code).

  • Left Quote Icon

    Student Picture

  • Left Quote Icon

    Student Picture

  • Left Quote Icon

    Student Picture