Skip to content

Instantly share code, notes, and snippets.

View samister2k's full-sized avatar

samister2k

View GitHub Profile
@samister2k
samister2k / main.py
Created September 5, 2018 10:54
ColorlessComplicatedAssociate created by samister2k - https://repl.it/@samister2k/ColorlessComplicatedAssociate
name = input("Say a name")
verb = input("Say a verb")
place = input("Say a place")
print(" " + name + " " + verb + " to " + place )
"""
Say a name sam
Say a verb ran
@samister2k
samister2k / business-keywords.py
Last active January 26, 2021 10:57
Business Studies keyword generator
print("welcome to the Business keyword generator")
print("these are your options as we are still working on this website")
print("Consumer")
print("Trader")
print("Brand name")
print("Contract")
print("Consideration")
print("Implied conditions")
print("3Rs")
print("Gurantee or Warranty")
<!DOCTYPE html>
<html>
<h1> Llamas and Alpaccas </h1>
<style>
.info {
color: red;
font-weight: bolder;
padding:20px;
import random #This allows you to generate random numbers an data.
name = ["Jordan", "Sam", "James", "Cian"] #This is a list its like a bag filled with names
role = ["leader", "researcher", "secretary", "mechanic", "protector", "presantator"] #Also a list
for num in range(4): #A loop creating 4 jobs to be assigned.
who = random.choice(name) #Random.choice grabs a random item from the list name.
job = random.choice(role) #Random.choice grabs a random item from the listrole.
print(who + job) #Prints out the role assigned to the person.
class Monster:
health = 15
def getScratch(self):
self.health = self.health - 2
def sayHealth(self):
print("my health is" + str(self.health))
def getThunder(self):
from time import sleep
print("This is my revison for python")
print("Theres a list of code that i will be using and telling you what it does")
sam = ["print", "sleep", "input", "while loop", "If else", "functions", "list", "for loop"]
print("sam")
while True:
choice=input("pick from the list")
if choice=="print":
print("The print() function prints the given object to the standard output device (screen) or to the text stream file.")
import RPi.GPIO as GPIO
from time import sleep
GPIO.setmode(GPIO.BCM)
GPIO.setup(23, GPIO.OUT)
GPIO.setup(24, GPIO.OUT)
GPIO.setup(17, GPIO.OUT)
GPIO.setup(27, GPIO.OUT)
GPIO.setup(11, GPIO.IN)
if i==1:
while True:
import RPi.GPIO as GPIO
from time import sleep
GPIO.setmode(GPIO.BCM)
GPIO.setup(23, GPIO.OUT).
GPIO.setup(24, GPIO.OUT).
GPIO.setup(17, GPIO.OUT).
GPIO.setup(27, GPIO.OUT).
import RPi.GPIO as GPIO
from time import sleep
GPIO.setmode(GPIO.BCM)
GPIO.setup(23, GPIO.OUT)
GPIO.setup(17, GPIO.OUT)
print("your motors are running ")
GPIO.output(23, GPIO.HIGH)
GPIO.output(17, GPIO.HIGH)
print("welcome to my program to translate english to German")
print("these are your options")
possible_words = ["hello","goodbye", "my name is", "what is that", "ye", "good evening", "good night", "happy", "ok", "thank you", "monday", "tuesday", "wednesday", "thursday", "friday", "saturday", "sunday"]
print(possible_words)
while True:
choice=input("type english")
if choice=="hello":
print("noun/verb")
print("Guten tag")