This file contains 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
int green = 2; | |
int yellow = 3; | |
int red = 4; | |
int trigPin = 5; | |
int echoPin = 6; | |
// ECHO to RX0 | |
long duration; | |
int distance; |
This file contains 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
# Interactive @ https://repl.it/@ItsMMgamer/EminentNavajowhiteLanserver | |
import random | |
choices = ['rock', 'paper', 'scissors'] | |
user_list = ['rock:scissors', 'scissors:paper', 'paper:rock', 'scissors:rock'] | |
computer_choice = random.choice(choices) | |
user_choice = str(input('Rock, Paper, Scissors?')) |
This file contains 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
def interval_intersect(a, b, c, d): | |
if (c <= b) and (a <= d) == False: | |
return False | |
else: | |
return True | |
def process(input: bool): | |
if input == False: | |
return "does not" | |
else: |
This file contains 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
# Interactive @ https://py3.codeskulptor.org/#user304_lfQquGbAhO_0.py | |
import math | |
def point_distance(x0: int, y0: int, x1: int, y1: int): | |
result = math.sqrt((x0 - x1) ** 2 + (y0 - y1) ** 2)) | |
return result | |
x1 = int(input("Value for x1: ")) |
This file contains 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
<label for="inp" class="inp"> | |
<input type="text" id="inp" placeholder=" "> | |
<span class="label">Label</span> | |
<span class="border"></span> | |
</label> |
This file contains 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
<div class="code-area"> | |
<span style="color: #777;font-style:italic;"> | |
// 404 page not found. | |
</span> | |
<span> | |
<span style="color:#d65562;"> | |
if | |
</span> | |
(<span style="color:#4ca8ef;">!</span><span style="font-style: italic;color:#bdbdbd;">found</span>) | |
{ |
This file contains 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
counter = 100 # A number | |
miles = 1000.0 # A floating point | |
name = "John" # A string (text) |
NewerOlder