This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import random | |
| print("GAME OF ROCK, SCISSORS, PAPER") | |
| print("CREATIVE COMPUTING") | |
| print("MORISSTOWN, NEW JERSEY") | |
| print("") | |
| numberOfGames = 0 | |
| while numberOfGames <= 0 or numberOfGames >= 10: | |
| numberOfGames = raw_input("HOW MANY GAMES?") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # This Template is intended for use with the Trinket.io web based | |
| # programming environment. Modification may be needed for use with | |
| # standard python interpreters on Windows, Mac, and Linux machines. | |
| # Import the Turtle 2D Graphics Module | |
| import turtle | |
| # Create Game Window | |
| screen = turtle.Screen() | |
| screen.setup(500, 500) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Import the Tkinter & Turtle Graphics Modules | |
| import Tkinter | |
| import turtle | |
| # Create Game Window | |
| screen = turtle.Screen() | |
| screen.screensize(500, 500, "black") | |
| # Create Sprite | |
| screen.addshape("sprite.gif") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // This gist demonstrates how to create a Rock, Paper, Scissors game in iOS using swift. | |
| // The "GAME OF ROCK, SCISSORS, PAPER" was originally published in David Ahl's | |
| // "Basic Computer Games" back in 1978. "Basic Computer Games" was comprised of 101 | |
| // computer games written in the BASIC programming language and was often used | |
| // by beginner programmers as a means of learning to code. Therefore, I've named | |
| // my iOS app written in Swift "Rock, Scissors, Paper" instead of "Rock, Paper, Scissors" | |
| // in honor of Ahl's book. | |
| // Note that this is a simple single view app with one ViewController. The view contains | |
| // a few static labels which do not change, and three buttons: ROCK, SCISSORS, PAPER. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Import the Tkinter & Turtle Graphics Modules | |
| import Tkinter | |
| import turtle | |
| # Create Game Window | |
| screen = turtle.Screen() | |
| screen.screensize(500, 500, "black") | |
| # Create Sprite Object Which Inherits from Turtle |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Tic Tac Toe assignmen that my student Grace is working on. | |
| # Saving here until she creates a github account. | |
| # Shruthi & Grace, Make Me Tic-Tac-Toe! | |
| # if you need to use random numbers.... | |
| # import random | |
| # randomNumber = random.randint(1, 10) | |
| # To print text on the screen: print("text goes here") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| // nl2p function by Anderson: https://www.guruqa.com/topic.php?t=6527 | |
| function nl2p($string, $line_breaks = true, $xml = true) { | |
| $string = str_replace(array('<p>', '</p>', '<br>', '<br />'), '', $string); | |
| // It is conceivable that people might still want single line-breaks | |
| // without breaking into a new paragraph. | |
| if ($line_breaks == true) { | |
| return '<p>'.preg_replace(array("/([\n]{2,})/i", "/([^>])\n([^<])/i"), array("</p>\n<p>", '$1<br'.($xml == true ? ' /' : '').'>$2'), trim($string)).'</p>'; | |
| } else { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!DOCTYPE html> | |
| <html> | |
| <body> | |
| <img src="crazymuppet.jpg"> | |
| <button id="play-btn" onClick="playAudio();">PLAY</button> | |
| <script> | |
| var laugh = new Audio("laugh.mp3"); | |
| function playAudio() { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| processor 6502 | |
| include "vcs.h" | |
| include "macro.h" | |
| seg Code | |
| org $f000 ; start code at $f000 | |
| Start sei ; disable interrupts | |
| cld ; disable BCD math mode |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| https://trinket.io/pygame/5f192e841f |