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
function isPasswordValid (input) { | |
if(!hasUppercase(input)) { | |
console.log('You need a capital letter'); | |
} | |
if (!hasLowercase(input)) { | |
console.log('Password needs a lowercase letter'); | |
} | |
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 java.util.*; | |
public class GCD{ | |
public static int gcd(int a, int b){ | |
if (b==0) return a; | |
return gcd(b, a%b); | |
}; | |
public static void main(String[] args){ |
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> | |
<head> | |
<link rel=stylesheet type="text/css" href="style.css"> | |
<script type="text/javascript" src="test.js"></script> | |
</head> | |
<body> | |
<p> Sample text </p> | |
</body> | |
</html> |
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 java.util.Scanner; | |
public class romanNum { | |
public static String convert(int num){ | |
int[] nums = new int[] {1000, 900, 500, 400, 100, | |
90, 50, 40, 10, 9, 5, 4, 1}; | |
String[] letters = new String[] { "M", "CM", "D", "CD", "C", "XC", | |
"L", "XL", "X", "IX", "V", "IV", "I" }; | |
String out = ""; | |
int times = 0; |
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
public class Test{ | |
private static class Node<E extends Comparable<E>>{ | |
E data; | |
Node<E> next; | |
public Node(E data){ | |
this.data = data; | |
this.next = null; | |
} | |
} |
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> | |
<head> | |
<title>The Eye</title> | |
<link rel="stylesheet" type="text/css" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css"> | |
<link rel="stylesheet" type="text/css" href="css"> | |
</head> | |
<body> |
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
<html> | |
<head> | |
<title>MY Times</title> | |
<link href="style.css" rel="stylesheet" type="text/css"> | |
<header> | |
<div class="logo"> | |
<img src="https://s3.amazonaws.com/codecademy-content/courses/freelance-1/unit-4/img-myt-logo.jpg"> | |
<span>My Times</span> | |
</div> | |
<nav> |
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> | |
<head> | |
<title>MY Times</title> | |
<link href="style.css" rel="stylesheet" type="text/css"> | |
<header> | |
<div class="logo"> | |
<img src="https://s3.amazonaws.com/codecademy-content/courses/freelance-1/unit-4/img-myt-logo.jpg"> | |
<span>My Times</span> | |
</div> |
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
#The program should do the following:Prompt the user to select either Rock, Paper, or Scissors. Instruct the computer to randomly select either Rock, Paper, or Scissors. Compare the user's choice and the computer's choice. Determine a winner (the user or the computer). Inform the user who the winner is | |
from random import randint | |
from time import sleep | |
options = ["R", "P", "S"] | |
LOSS_MESSAGE = "You lost!" | |
WIN_MESSAGE = "You won!" | |
def decide_winner(user_choice, computer_choice): | |
print "You selected: %s" % user_choice | |
sleep(1) |
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
#The program should do the following:Prompt the user to select either Rock, Paper, or Scissors. Instruct the computer to randomly select either Rock, Paper, or Scissors. Compare the user's choice and the computer's choice. Determine a winner (the user or the computer). Inform the user who the winner is | |
from random import randint | |
from time import sleep | |
options = ["R", "P", "S"] | |
LOSS_MESSAGE = "You lost!" | |
WIN_MESSAGE = "You won!" | |
def decide_winner(user_choice, computer_choice): | |
print "You selected: %s" % user_choice | |
sleep(1) |
OlderNewer