Skip to content

Instantly share code, notes, and snippets.

Avatar

Steve Fasano sfasano

View GitHub Profile
@sfasano
sfasano / buttonClassIssue.html
Last active Aug 29, 2015
I'm having an issue with reassigning the Button to .second
View buttonClassIssue.html
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>One Button Two Times</title>
</head>
<body>
View stevesGuessingGame.html
<script type="text/javascript">
// Declare variables
var userGuess, userChoice, answer;
// Present user with two options
do {
userChoice = prompt('Would you like to choose your own number, or have the computer randomly choose for you? \
1: Choose \
2: Random');
} while (userChoice != '1' && userChoice != '2');
@sfasano
sfasano / primeGuess.html
Created Nov 11, 2014
My Prime Guessing Game
View primeGuess.html
<html>
<script>
var guess;
var prime = 2;
var isPrime = function(prime) {
for (var count = 2; count < prime; count++){
if (prime % count == 0){
return false;